/* Date:29/10/2008 Author: Deepak Majeti report bugs to: mdeepak@cse.iitk.ac.in */ // 1. Create an array with enteries randomly selected from range 0 to 99. The // length of the array should be read from command line. Print the array on the monitor. // Now sort the array in decreasing order and print the sorted array on the monitor. class ArraySort{ public static void main(String args[]){ int array[]=null; int arraySize=0; int temp=0; try{ arraySize=Integer.parseInt(args[0]); }catch(Exception e){ System.out.println("Please enter and integer(array size) as argument"); System.exit(0); } array=new int[arraySize]; //fill the array randomly using numbers between 0-99 and print them System.out.println("Array being generated. The "+ arraySize+" numbers are:"); for(int i=0;i