Using a programming language of your choice, compose two string analysis functions as described in the following problems:
- Create a function that takes one string as an argument and outputs a report indicating how many characters that string has.
- The function also checks if the given string is a palindrome and includes this information in the report.
- A palindrome is a word, phrase, or sequence that reads the same backwards as forwards, e.g. "madam".
Sample output:
"madam" has 5 characters.
"madam" is a palindrome.- Write a new function that takes two strings as arguments. The function needs to check if given strings are anagrams of each other, and include this information in an output report.
- An anagram is a word or phrase formed by rearranging the letters of a different word or phrase using all the original letters exactly once, e.g. "debit card" and "bad credit".
- The report needs to include also if the provided strings contain numbers.
Sample output:
"listen" and "silent" are anagrams of each other.
There are no numbers in "listen".
There are no numbers in "silent".Consider optimising your solution, or providing unit tests.
Your solution should be runnable and output the reports mentioned above in the format of your choice.