Java classical algorithm: 1,2,3,4 figures, the number of other with no repeat of the three-digit numbers can be composed? How much are?

Package Penalty for the Test; 
 
/ ** 
 * Title: 1,2,3,4 figures, the number of other with no repeat of the three-digit numbers can be composed? How much are? 
 * / 
Public  class ZuHe {
     public  static  void main (String [] args) {
         for ( int I =. 1; I <=. 4; I ++ ) {
             for ( int J =. 1; J <=. 4; J ++ ) {
                 for ( int K =. 1; K <=. 4; K ++ ) {
                     // each not equal 
                    IF (I = J && I = K && J =!!! K) { 
                        System.out.println ( 100 * I + 10 * J + K); 
                    } 
                } 
            }
        }
    }
}

From the micro-channel public number: Programming Society

Advanced programmers daily book, please pay attention!

 

Guess you like

Origin www.cnblogs.com/ai10999/p/11448708.html