Write a static method that receives a String. It should return true
if the string ends in 'ly' (lowercase only).
You must use .substring()
.
Examples:
endsInLy("suddenly")
returns true
endsInLy("SUDDENLY")
returns false
endsInLy("suddenly I saw the rescue train")
returns false
endsInLy("well")
returns false
©2003–2016 Graham Mitchell
This assignment is licensed under a
Creative Commons Attribution-NonCommercial-ShareAlike 3.0 United States License.