Snippets tagged “null-pointer-exception”
2 snippets use this tag.
- If statement with String comparison failsJava
If an if statement with a string comparison fails in Java, it usually means that the strings being compared are not equal.
- Java - removing first character of a stringJava
To remove the first character of a string in Java, you can use the substring() method of the String class.