Created
September 23, 2012 15:34
-
-
Save edipofederle/3772052 to your computer and use it in GitHub Desktop.
square2.hs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import Test.QuickCheck | |
| import Data.List | |
| square :: [Double] -> [Double] | |
| square (x:xs) = x*x : square xs | |
| square [] = [] | |
| -- testing | |
| prop_test1 xs = not(null xs) ==> map(1*) ( square xs ) == map (\x -> x * x) xs |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment