java
javaWrte a method to find if 2 given Strngs are anagrams Wte a man mothod that cals this mothod with 2 Strings and prints the resut 2 words ane anagrams if they are of equal length and made of same characters but the order of occumence mght be diterent (Remember Java is case senstive- so make sure to use the buit in methods gven by String clss to sick with ether uppercase or lowercase) Sample Input Ender word #1: Isten Enter word #2 slent Expected output isten and sient are anagrams Sample Input Enter word #1 holo Enter word #2 te Expected outpd helo and he are not anagrams Write a method to find if 2 given Strings are anagrams. Write a main method that calls this method with 2 Strings and prints the result. 2 words are anagrams if they are of equal length and made of the same characters but the order of occurrence might be different. (Remember Java is case sensitive – so make sure to use the built-in methods given by String class to stick with either uppercase or lowercase) Sample Input: Enter word # 1: listen Enter word # 2: silent Expected output: listen and silent are anagrams I Sample Input: Enter word # 1: hello Enter word # 2: he Expected output: hello and he are not anagrams Show transcribed image text Wrte a method to find if 2 given Strngs are anagrams Wte a man mothod that cals this mothod with 2 Strings and prints the resut 2 words ane anagrams if they are of equal length and made of same characters but the order of occumence mght be diterent (Remember Java is case senstive- so make sure to use the buit in methods gven by String clss to sick with ether uppercase or lowercase) Sample Input Ender word #1: Isten Enter word #2 slent Expected output isten and sient are anagrams Sample Input Enter word #1 holo Enter word #2 te Expected outpd helo and he are not anagrams
Write a method to find if 2 given Strings are anagrams. Write a main method that calls this method with 2 Strings and prints the result. 2 words are anagrams if they are of equal length and made of the same characters but the order of occurrence might be different. (Remember Java is case sensitive – so make sure to use the built-in methods given by String class to stick with either uppercase or lowercase) Sample Input: Enter word # 1: listen Enter word # 2: silent Expected output: listen and silent are anagrams I Sample Input: Enter word # 1: hello Enter word # 2: he Expected output: hello and he are not anagrams
Expert Answer
Answer to Wrte a method to find if 2 given Strngs are anagrams Wte a man mothod that cals this mothod with 2 Strings and prints th…