Which of the following loops are equivalent?

(i). \(while(x\le10)\)

      {

         x++;

       }

(ii). \(if(x\le10)\)

  {

      do

           {

              x++;

            } \(while(x\le10) \)

   }

(iii)

  while(true)

   {

     if(x>10) break;

     x++;

  }

1
Only (i) and (ii)
2
Only (ii) and (iii)
3
Only (i) and (iii)
4
All are equivalent

Sponsored

hivanix.in

Visit

This quiz is brought to you by hivanix.in

🌐 Web App Development

Quick Navigation