Q. Which of the following is valid syntax for creating a while loop?
β
Correct Answer: (B)
while(condition){ }
Explanation: The correct syntax for creating a while loop is:
while(condition){
}