id/email
password
forgot password
about | help | done | prefs | create account
CodingBat code practice

Java > String-2 > endOther
prev  |  next  |  chance

Given two strings, return true if either of the strings appears at the very end of the other string, ignoring upper/lower case differences (in other words, the computation should not be "case sensitive"). Note: str.toLowerCase() returns the lowercase version of a string.

endOther("Hiabc", "abc") → true
endOther("AbC", "HiaBc") → true
endOther("abc", "abXabc") → true

...Save, Compile, Run

See also Java Example Code. Java help docs: If Boolean Logic | Strings | While and For Loops | Arrays and Loops


prev  |  next  |  chance   |  CodingBat  >  String-2

Forget It! -- delete my code for this problem 215.0

Copyright Nick Parlante 2006-10 - privacy