code: public Permutation invert() {
          Permutation inversion = new Permutation(values.length);
          for (int i = 0; i < values.length; i++) {
              inversion.values[this.values[i]] = i;
          }
          return inversion;
      }
docs: Invert the permutation, so that for all i : inv[p[i]] = i.
  
  @return the inverse of this permutation