do while in c++
do {
// code here
}
while (condition);
// examples
#include <iostream>
using namespace std;
int main () {
int i = 0;
do {
cout << i << "n";
i++;
}
while (i < 10);
}
do while in c++
do {
// code here
}
while (condition);
// examples
#include <iostream>
using namespace std;
int main () {
int i = 0;
do {
cout << i << "n";
i++;
}
while (i < 10);
}
c++ while loop
while (test_expression)
{
// statements
update_expression;
}
c++ while loop examples
while (condition) {
// body of the loop
}
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us