public static void main(String[] args) { String str="跳水,跑步,听音乐,看书,"; System.out.println(str.substring(0, str.length() -1)); }