Created
August 4, 2020 10:29
-
-
Save AakashCode12/5e9190e09993c6816e7031ce429b0686 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class cmd_line{ | |
public static void main(String args[]){ | |
int a=Integer.parseInt(args[0]); | |
int b=Integer.parseInt(args[1]); | |
//! condition example | |
System.out.println("The condition Example"); | |
System.out.println("The greater no between the two\n"); | |
if(a>b){ | |
System.out.println("the number "+a+" is greater than "+b); | |
} | |
else{ | |
System.out.println("the number "+b+" is greater than "+a); | |
} | |
//! looping example | |
System.out.println("The Pattern using loops is :"); | |
for(int i=0;i<5;i++){ | |
for(int j=0;j<i;j++){ | |
System.out.print("*"); | |
} | |
System.out.println(); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment