Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
could you explain it?
Could you explain it?
Your solution does not even pass sample tests. You can start with debugging these locally.
This comment is hidden because it contains spoiler information about the solution
Ohhh now got it, thanks
you need a function that adds two numbers and by not carrying over the digits so 11+11=22 and 88+88=1616. This way the function will pass all the tests :)
But I'm not able to understand how I can write the function. For example, if return
num1 + num2
, these it passes for the first set of test cases, however not in the 2nd set of cases and vice versa.Ah i see thanks! haha..
The real, silly, and big addition names are describing the test not a type of function used. You always perform the same operation as described in the description. The tests then do a few examples where the result of the fucntion is what would be expected with 'real' addition; then some where you have to remember not to carry the difits; and then some where the input numbers get quite big.
How do I know if the output should be Real, Silly or Big addition?
Is there some kind of variable passed down?
It makes debugging easier - you know on what sort of test your code is failing on.
Why there is two set of test cases, one with original addition and onw with the fake one? In both set of test cases, it is calling the same method.
You just do addition but instaead of carrying the numbers over, you just write make a new digit in the number.
So 11 + 11 = 22
So 88 + 88 = 1616
Finally it worked! Thanks.
Loading more items...