WhileExample Program

public class WhileExample

 { 
public static void main(String[] args) 




    int i=1; 
    while(i<=10)





        System.out.println(i); 
                i++; 
    } 

}

Comments

  1. (String ()args)
    (String args () )
    Which is correct

    ReplyDelete
  2. both are correct but we have to write like this (String[] args) or (String args[])





    ReplyDelete

Post a Comment