From 4a9156cc72bad6f081bb23944bc160c3ea0fa809 Mon Sep 17 00:00:00 2001 From: Kiranmai1106 <71929885+Kiranmai1106@users.noreply.github.com> Date: Sat, 3 Oct 2020 22:27:01 +0530 Subject: [PATCH] Create pyramid.java --- pyramid.java | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 pyramid.java diff --git a/pyramid.java b/pyramid.java new file mode 100644 index 0000000..894fca1 --- /dev/null +++ b/pyramid.java @@ -0,0 +1,54 @@ + +import java.io.*; + + +// Java code to demonstrate star patterns + +public class GeeksForGeeks +{ + + // Function to demonstrate printing pattern + + public static void printStars(int n) + + { + + int i, j; + + + + // outer loop to handle number of rows + + // n in this case + + for(i=0; i