Palindrome tester with Java, ignoring spaces and punctuation

后端 未结 7 1360
忘了有多久
忘了有多久 2021-01-07 04:26

I have the program made up until the point where it has to ignore and punctuations and spaces in the thread and I was wondering if anyone could help me with the coding for t

相关标签:
7条回答
  • 2021-01-07 05:05

    Look at char's documentation entry. Specifically the isLetterOrDigit method. If that method returns false, then it's punctuation or a space. There are other methods in there as well that can help with that.

    0 讨论(0)
提交回复
热议问题