๐Ÿ”ฅ Lohri โ€ข ๐Ÿช Makar Sankranti โ€ข ๐Ÿ‡ฎ๐Ÿ‡ณ Republic Day | Offers | Upto 70% OFF + Extra 26% OFF โ€” One Coupon for All Courses โ†’ BHARAT26 ( Limited Period Celebration Offer ) << Explore Professional Courses >>

Solid Square Star Pattern Program in Java  


Program:
* * * * *
* * * * *
* * * * *
* * * * *
* * * * *
  • Program:
    public class StarPattern14
    {
        public static void main(String[] args)
        {
            for(int i=1; i<=5; i++)
            {
                for(int j=1; j<=5; j++)
                {
                    System.out.print("*");
                }
                System.out.println();
            }
        }
    }