- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
public static String trimLastSemicolon(String str)
{
if(str != null)
{
if(str.endsWith(";"))
{
int pos = str.length() - 1;
while(pos >= 0)
{
if(str.charAt(pos) == ';')
pos--;
else
break;
}
if(pos >= 0)
return str.substring(0, pos + 1);
else
return "";
}
else
return str;
}
return null;
}
CrashTesterAnusov 21.09.2016 21:30 # −64
_inpu_ 22.09.2016 10:23 # 0
inkanus-gray 23.09.2016 14:05 # 0
guest 23.09.2016 21:26 # 0
1024-- 23.09.2016 21:41 # 0
barop 23.09.2016 21:45 # +1
wissenstein 25.11.2016 19:02 # 0