mirror of
https://gitflic.ru/project/w0lf/bulls-and-cows-cpp.git
synced 2026-03-28 16:02:46 +03:00
Refactored the PrintSteps() method.
This commit is contained in:
@@ -125,12 +125,10 @@ void CGame::PrintSteps()
|
|||||||
|
|
||||||
for (CStep& s : m_Steps)
|
for (CStep& s : m_Steps)
|
||||||
{
|
{
|
||||||
std::wstring stepNumber = L"\0";
|
std::wcout << '\t';
|
||||||
for (int& d : s.GetStepNumber())
|
for (auto& d : s.GetStepNumber()) std::wcout << d;
|
||||||
{
|
std::wcout << '\t' << s.GetStepAnimals().first << L" Б., " << s.GetStepAnimals().second << L" К.";
|
||||||
stepNumber += std::to_wstring(d);
|
std::wcout << std::endl;
|
||||||
}
|
|
||||||
std::wcout << '\t' << stepNumber << '\t' << s.GetStepAnimals().first << L" Б., " << s.GetStepAnimals().second << L" К." << std::endl;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user