void scramble(){
  initialSize=getSize();
  int a[]=new int[initialSize.height / 2];
  double f=initialSize.width / (double)a.length;
  for (int i=a.length; --i >= 0; ) {
    a[i]=(int)(i * f);
  }
  for (int i=a.length; --i >= 0; ) {
    int j=(int)(i * Math.random());
    int t=a[i];
    a[i]=a[j];
    a[j]=t;
  }
  arr=a;
}

void scramble ( ) { initialSize = getSize ( ) ; int a [ ] = new int [ initialSize . height / 2 ] ; double f = initialSize . width / ( double ) a . length ; for ( int i = a . length ; -- i >= 0 ; ) { a [ i ] = ( int ) ( i * f ) ; } for ( int i = a . length ; -- i >= 0 ; ) { int j = ( int ) ( i * Math . random ( ) ) ; int t = a [ i ] ; a [ i ] = a [ j ] ; a [ j ] = t ; } arr = a ; }
fill the array with random numbers from 0 . . n - 1 .
