Ad
  • Custom User Avatar

    Could you switch the argument name as well? It can be confusing.

    next xs item = error "Not implemented"
    

    to:

    next item xs = error "Not implemented"
    
  • Custom User Avatar

    +1 for stop.

  • Custom User Avatar

    Actually, only one is given in one of the test cases when calling Plugboard() without any arguments for testing empty construction. Honestly, I think it should be Plugboard('') for empty pairing.

  • Custom User Avatar
  • Custom User Avatar

    Radii is the plural form of radius (thanks to the irregularity of English).

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    The test case does not test for input validation.

    Write a function called sortGiftCode (sort_gift_code in Ruby) that accepts a string containing up to 26 unique alphabetical characters, and returns a string containing the same characters in alphabetical order.

  • Custom User Avatar

    Who likes keywords? Nobody likes keywords, so why use them?

  • Custom User Avatar

    Haskell's function arguments are switched.

    It is currenty:

    next :: Eq a => [a] -> a -> Maybe a
    next xs item = error "Not implemented"
    

    while it should be:

    next :: Eq a => a -> [a] -> Maybe a
    next item xs = error "Not implemented"
    
  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    In Haskell, the type checking freaks out because the solution has type of Int -> String, but it gets Integer as input for test cases.

    So, the type of solution should be either:

    solution :: Integer -> String

    or more generally:

    solution :: Integral a => a -> String

  • Custom User Avatar

    Would you kindly put colons at the end of function definition in Python?

  • Custom User Avatar

    The Python one seems incomplete.

    Test cases have error, and the solution test cases only check once.

  • Custom User Avatar

    The submit test has test case for empty list, but the test cases doesn't.

    I think the wording is a bit vague. You should say, "you are not allowed to use Data.List or Data.Strings.Utils modules." (or something like that). I was puzzled because when you said join functions, I thought it meant functions starting with join which does not exist.

  • Custom User Avatar

    Typo: (>>=) :: m a -> (a -> m a) -> m b

    should be: (>>=) :: m a -> (a -> m b) -> m b

  • Loading more items...