SyntaxFix
Write A Post
Hire A Developer
Questions
[+]is simpler
String s = "ddjdjdj+kfkfkf"; if(s.contains ("+")) { String parts[] = s.split("[+]"); s = parts[0]; // i want to strip part after + } System.out.println(s);