Java String Chop chop(String x)

Here you can find the source of chop(String x)

Description

chop

License

Open Source License

Declaration

public static String chop(String x) 

Method Source Code

//package com.java2s;

public class Main {
    public static String chop(String x) {
        if (x.length() == 0)
            return x;
        return x.substring(0, x.length() - 1);
    }/*from   ww w  .ja va 2  s .  c o  m*/
}

Related

  1. chop(String str)
  2. chop(String str, int maxLength)
  3. chop(String string, int length)
  4. chop(String string, int length)
  5. chop(String value, int size)
  6. chop(String[] arr, int pos)
  7. chop(StringBuffer buffer, int chars)
  8. chopAccelerator(final String title)
  9. ChopAllLf(String this_string, String chomp_off)