Skip to content
Snippets Groups Projects
Verified Commit d4d30944 authored by Sébastien Villemot's avatar Sébastien Villemot
Browse files

Simplification using a range-based for loop

parent 06e82f80
Branches
No related tags found
No related merge requests found
......@@ -77,12 +77,8 @@ OrdSequence::add(int i)
void
OrdSequence::add(const OrdSequence& s)
{
auto vit = s.data.begin();
while (vit != s.data.end())
{
add(*vit);
++vit;
}
for (int i : s.data)
add(i);
}
/* Answers true if a given number is in the class. */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment