All pastes #947540 Raw Edit

gfry

public text v1 · immutable
·published 2008-03-18 15:48 UTC
rendered paste body
public class RandomComponentArray {
    
    public static void main(String[] args) {
    int small = 1000;
    int big = 0;
    int[] num = new int[10]; 
    for (int i = 0; i< 10; i++){
                num[i]=(int)(Math.random()*100+0);      
    big=Math.max(0,num[i]);
    small=Math.min(num[i], small);
    }   
        System.out.println("The biggest number is "+ big );
        System.out.println("The smallest number is "+ small );
    }
}