code: double error(int[] x, int[] y) {
          int e = 0;
  
          for (int i = 0; i < x.length; i++) {
              if (x[i] != y[i]) {
                  e++;
              }
          }
  
          return (double) e / x.length;
      }
docs: Returns the error rate.