Posts

Showing posts with the label Pattern

StairCase HackerRank Algorithms Practice

TIME O(N^2)  SPACE O(1)   public   static   void  staircase( int  n) {          for ( int  i= 0 ;i<n;i++){              for ( int  j= 0 ;j<n;j++){                  if (j<n- 1 -i){                     System.out.print( " " );                 }                  else                     System.out.print( "#" );             }    ...