The U-n-KNOWN but known variables: Multiplication
Description:
This kata is definitely harder than the first one. See the last one here: http://www.codewars.com/kata/the-unknown-but-known-variables-addition
This one is a programming problem as well as a puzzle. And this is one of those annoying puzzles that is going to seem impossible, as the answer is not like a riddle, but something random some jerk over the internet came up with. But I have confidence you will solve it.
There will be a string input in this format:
'a*b'
2 lower-case letters (a-z) seperated by a '*'
Return the product of the two variables. The product will always be a positive integer or 0.
There is one correct answer for a pair of variables.
I know the answers, it is your task to find out.
Once you crack the code for a couple of the pairs, you should have the answer for the rest.
It is like when you were in school doing math and you saw "12 = c*b"
and you needed to find out what c and b were.
However you don't have a 12. You have an UnKNOWN there as well. Example:
X = a*b.
You don't know what X is, and you don't know what b is or a, but it is a puzzle and you will find out.
As part of this puzzle, there is two hints or clues on solving this. I won't tell you what the other one is. But the first is: The key is in the title.
Given the input as a string - Return the product of the two variables as int.
Similar Kata:
Stats:
Created | Apr 22, 2016 |
Published | Apr 25, 2016 |
Warriors Trained | 344 |
Total Skips | 11 |
Total Code Submissions | 948 |
Total Times Completed | 152 |
Python Completions | 152 |
Total Stars | 5 |
% of votes with a positive feedback rating | 95% of 58 |
Total "Very Satisfied" Votes | 53 |
Total "Somewhat Satisfied" Votes | 4 |
Total "Not Satisfied" Votes | 1 |
Total Rank Assessments | 9 |
Average Assessed Rank | 6 kyu |
Highest Assessed Rank | 5 kyu |
Lowest Assessed Rank | 8 kyu |