import java.util.*;
public class Number
{
public static void main(String args [])
{
Scanner sc = new Scanner (System.in);
for(int i = 1; ; i++)
{
System.out.println(i);
}
}
}
Give the Output
Under discussion
Comments (2)
- Popular
- New
- Old
You must be signed in to leave a comment
Manabendra Saha 1043
20 September 2022, 17:53
for(int i = 1; i<=5 ; i++)//let assume to run a for loop from 1 to 5..
it will print numbers as-
1
2
3
4
5
0
Manabendra Saha 1043
20 September 2022, 17:51
syntax error
0