Java examples for java.lang:StringBuilder
delete Last Char from StringBuilder
//package com.java2s; public class Main { public static void main(String[] argv) throws Exception { StringBuilder sb = new StringBuilder(); deleteLastChar(sb);//from ww w .ja v a 2 s. co m } public static void deleteLastChar(StringBuilder sb) { sb.deleteCharAt(sb.length() - 1); } }