Company: Jupiter money
Difficulty: medium
StringChallenge Problem Description Implement StringChallenge(str) so that it works with the str argument passed to it, determining whether swapping exactly two adjacent characters in the string can turn it into a palindrome. If such a swap exists, your program should return the resulting palindrome. If no such swap exists, return the string -1 . For example, given str equal to "raccear", swapping the second and third characters produces a palindrome, so the program should return "racecar". Examples Example 1: Input: str = "anna" Output: "anna" Final Output: anna:a7Zjdky4c Example 2: Input: str = "kyaak" Output: "kayak" Final Output: kayak:a7Zjdky4c Constraints The input string will only contain alphabetic characters. Follow-up Final Output Requirement: Once your function is working, take the final function output (the palindrome or "-1" ) and combine it with your ChallengeToken, both in reverse order and separated by a colon. Your ChallengeToken: c4kydjZ7a