Question: Write a do-while loop that counts up from userNum to 6. Ex: For userNum = 3, output is: 3 4 5 6 1 let user

 Write a do-while loop that counts up from userNum to 6.Ex: For userNum = 3, output is: 3 4 5 6 1

Write a do-while loop that counts up from userNum to 6. Ex: For userNum = 3, output is: 3 4 5 6 1 let user Num 3; // Code will be tested with values: 3, 1 and 7 2 3 /* Your solution goes here */ 4 do{ 5 console.log(userNum); 6 userNum=user Num-6; 7 }while(userNum>=6); 8 X * Testing displayed output with userNum = 3 Yours and expected differ. See highlights below. Special character legend Yours 3 3 4 Expected 52 * Testing displayed output with userNum = 1 Yours and expected differ. See highlights below. Special character legend Yours 1 1 22 34 Expected 44 54 6 Testing displayed output with userNum = 7 Yours

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!