areReversals
Category: Programming
Author: Benson Limketkai
Book Chapter: 4.3
Problem: areReversals
Write a static method named areReversals that accepts two strings and returns true if the strings are reversals of each other, i.e. if one word is equal to the other word spelled backwards. Case does not matter. Here are some example calls to the method and their expected return results: Call | Value Returned ------------------------------------|----------------- areReversals("hello", "goodbye") | false areReversals("hello", "olleh") | true areReversals("HELLO", "olleh") | true areReversals("hello", "aolleh") | false