There should be a specific test with 0 in Haskell. There is a random test using 0... but it is not enough!
The test use
n <- choose (0, 100 :: Int)
If you repeat this random test 100 times, the probablility to pass the test using 0 is 50%
So, there are some people using foldl1 that pass the tests. These foldl1 solutions MUST fail the test with 0
You're simply printing a string and returning a number, not what you should do, read the instructions again.
Nice one - glad I could help!
Thank you so much! I found it were that the data was outputting to much data so when you said to check my loop i knew it couldnt have been that since its just iterating n times then i relised it was the Console.WriteLines's i had!
Thank you for your service.
This error happens when the code is outputting too much data to the log window. So this could be caused by using Console.WriteLine a lot or by writing to the log window inside an (infinite) loop. Have a careful look to make sure the loop is being terminated.
If you aren't sure, feel free to post the code and check the "Mark as having spoiler content" checkbox.
I wanna believe im learning i really do but it seems im getting a Max Buffer Size Reached (1.5 MiB) error?
Using C# btw
Max Buffer Size Reached (1.5 MiB)
Thank you for reviewing the translation.
@Zenonz I don't think so. Anyone calling such a function will have to check if the result is NULL. If you really want and need to optimize things, you shouldn't use always-dynamically allocated, zero-terminated strings that don't even have their lengths stored in the first place.
the test with 0 should accept NULL as a valid answer.
Interesting for me in C++, to begin to use std::to_string and concatenate chains of characters. Good kata.
This comment is hidden because it contains spoiler information about the solution