We post one challenging problem here every week. Solution due is 11:59 PM every Friday. We offer awards to two responders. 1. The first one with the right solution. 2. The correct solution with fewest code statements.
If we get only one correct solution, we will skip the award for the fewest code statements.
You need to create an account in this club in order to participate in this competition. The solution can use one of these three languages: Java, Python, JavaScript. You can submit your solution to this topic. Make sure your name and email account are in the end of the solution.
If you want that we indent your code correctly, please submit your code to this challenge along with a screenshot of your code in your IDE or your code file as an attachment. Remember you still need to submit your code as text here. Thanks for your participation.
Problem: Yesterday, Tom played a new game. He asked the user to input a string with at least 10 characters. Then he grouped the characters in three groups so each group had the same sum of the Unicode value of the characters. If the string had less than 10 characters, or if the string had characters that were not numeric-alphabetic, Tom did not accept that input and threw null out. Tom was allowed to exclude one character and no more than one character from the input in order to group the input into three equal groups. If he could not find those three groups, he also threw null out. If he did successfully group them, he returned those three groups as three items in an array. Can you help Tom write such a method? You then take a user input and print out those three groups one by one. Print 0 if a null is thrown.