Question: Could you please explain to me how the do and the while functions work in this program? #include using namespace std; int main() { int

Could you please explain to me how the do and the while functions work in this program?

Could you please explain to me how the do and the while

#include

using namespace std;

int main()

{

int num1, num2;

int temp = 0;

cout

cin >> num1 >> num2;

cout

do

{

temp = num1 + num2;

num1 = num2;

num2 = temp;

cout

}

while (((num1 + num2) % 5) != 0);

cout

return 0;

}

#include using namespace std; int main() int num1, num2; int temp = 0; cout > numl >> num2; cout

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!