Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

java

*
   #*#
  ##*##
 ###*###
 
 
 
 import java.util.Scanner;

public class Main {

	
	public static void main(String[] args) {
		
        
        Scanner sc= new Scanner(System.in);
        
        int n= sc.nextInt();
        
       for(int row=1;row<=n;row++)
       {
           for(int space=1;space<=n-row;rpw++)
           {
               System.out.print(" ");
           }
           
           for(int num=1;num<=row;num++)
           {
               System.out.print("*")
           }
       }

	}

}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #java
ADD COMMENT
Topic
Name
7+6 =