Move History

Fork Selected
  • Description

    Given 2 lists, find if one is the scramble of the other. If it is, return True, else return False

    Code
    module Scramble where 
    
    scramble :: String -> String -> Bool
    scramble a b = "Scarmble this up"
    Test Cases Failed
    module ScrambleSpec where
    
    
    import Test.Hspec 
    import Scramble 
    
    spec :: Spec
    spec = do
       it "Test Cases" $ do
        scramble "scramble" "scarmble" `shouldBe` True
        scramble "scroomble" "scroomble" `shouldBe` False
        scramble "ScrooMBle" "totally random thing jalkdfjlskfdjlksjdfldjs" `shouldBe` False
        scramble "qwertyuiop" "QWERTYUIOP" `shouldBe False