How to print Number Pyramid Pattern in java? 12:33 AM Posted by Altaf Java No Comments package com.npp.test; public class Test { public static void main(String[] args) { int n=9; for(int i=n;i>=1;i--){ for(int j=n;j>=1;j--){ System.out.print(j>i?" ":i+" "); } System.out.println(); } } } How to print Number Pyramid Pattern in java? Share this
0 Comment to "How to print Number Pyramid Pattern in java?"
Post a Comment