Create a Kotlin function to determine whether two given strings are anagrams of each other, ignoring case and any non-alphabetic characters. An anagram uses all the original letters exactly once.
Task Description:
- Implement a function named
isAnagram
that takes two strings as input. - The function should return
true
if the two strings are anagrams of each other (case-insensitive) andfalse
otherwise. - Ignore non-alphabetic characters when determining anagrams.
- Fill in the code.
- You can copy the code into IntelliJ/Android Studio, but it shouldn’t be necessary.
- Click “run” – the green triangle. The code will compile and several tests will be run.
- In the logs, you will see “try again” if the solution is incorrect, or “success” and a special code.
- Provide this code in the form below along with your email and click “send”.