// display all elements of an array (with bar charts, etc.) float [] jh = {99.1,33.2,44.3, 22.4, 66.7}; int many= jh.length; int nextX, nextY; // coords of next display. final int FIRSTX=10, FIRSTY=20, SPACING=17; float multiplier; float big=100; void setup() { size(640,480); } void draw() // Draw a frame { //big= biggest( jh ); //big= biggest( jh ); int k= whereBig( jh ); big= jh[k]; // find biggest value in jh multiplier= (width-90)/big; scene(); show(); } void scene() // Draw Scene { background(0,200,255); } void show() //Show all elements of the array jh[] { nextX= FIRSTX; nextY= FIRSTY; for (int p=0; p=1) float result= z[0]; for(int p=1; p < z.length; p++) { if(z[p] > result) result = z[p]; display( z[p] ); } return result; } int whereBig(float[]z) { int w=0; for( int p=1; p < z.length; p++) { if(z[p]>z[w]) w=p; } return w; } void swap(float[]z, int i, int p) { // exchange two columns of an array float temp; temp=jh[i]; jh[i] = jh[p]; jh[p] = temp; }