do while loop to while loop c++ code example Example: c++ do while loop do { // codes; } while (testExpression);