This comment is hidden because it contains spoiler information about the solution
I have to open this issue again. Still getting the same error.
In your solution isFloat catches most of the invalid input, but not all. For example, if the argument contains more than one decimal mark (e.g. "123..2" or "123.1.2"), the read function fails.
Haskell version shows no test cases. Thus "Run sample tests" button lead to error.
IMHO too easy on Haskell, even for 8 kyu.
IIRC in this case there is no need to explicitly annotate the type of (read x), because the compiler is able to derive it from function signature.
Loading collection data...
This comment is hidden because it contains spoiler information about the solution
I have to open this issue again. Still getting the same error.
This comment is hidden because it contains spoiler information about the solution
In your solution isFloat catches most of the invalid input, but not all. For example, if the argument contains more than one decimal mark (e.g. "123..2" or "123.1.2"), the read function fails.
Haskell version shows no test cases. Thus "Run sample tests" button lead to error.
IMHO too easy on Haskell, even for 8 kyu.
IIRC in this case there is no need to explicitly annotate the type of (read x), because the compiler is able to derive it from function signature.