My assignment in my Java course is to make 3 triangles. One left aligned, one right aligned, and one centered. I have to make a menu for what type of triangle and then input
public class triangle { public static void main ( String arg[] ){ System.out.print("Enter Triangle Size : "); int num=0; try{ num=Integer.parseInt( read.readLine() ); } catch(Exception Number){ System.out.println("Invalid Number!"); } for(int i=1;i<=num;i++){ for(int j=1;j