PLEASE EXPLAIN ME THE OUTPUT OF THE FOLLOWING CONDITION | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

PLEASE EXPLAIN ME THE OUTPUT OF THE FOLLOWING CONDITION

for( ; ; ;) { System.out.println("I love coding"); }

9th Jul 2017, 9:13 AM
Arijit Ray
Arijit Ray - avatar
2 Answers
+ 6
it might give you an error because in your for loop there are 3 semicolons but it should be 2 to give an infinite loop
9th Jul 2017, 9:56 AM
Vaibhav Tandon
Vaibhav Tandon - avatar
+ 1
thanks man
11th Jul 2017, 2:09 AM
Arijit Ray
Arijit Ray - avatar