code: private void step1()
      {
          if (b[k] == 's')
          {
              if (ends("sses")) k -= 2;
              else if (ends("ies")) setto("i");
              else if (b[k - 1] != 's') k--;
          }
          if (ends("eed"))
          {
              if (m() > 0) k--;
          }
          else if ((ends("ed") || ends("ing")) && vowelinstem())
          {
              k = j;
              if (ends("at")) setto("ate");
              else if (ends("bl")) setto("ble");
              else if (ends("iz")) setto("ize");
              else if (doublec(k))
              {
                  int ch = b[k--];
                  if (ch == 'l' || ch == 's' || ch == 'z') k++;
              }
              else if (m() == 1 && cvc(k)) setto("e");
          }
      }
docs: /*
  step1() gets rid of plurals and -ed or -ing. e.g.
  
  caresses -> caress ponies -> poni ties -> ti caress -> caress cats -> cat
  
  feed -> feed agreed -> agree disabled -> disable
  
  matting -> mat mating -> mate meeting -> meet milling -> mill messing ->
  mess
  
  meetings -> meet