a. Haskell is a strict functional language b. Haskell is a pure functional langu
ID: 3609671 • Letter: A
Question
a. Haskell is a strict functional language
b. Haskell is a pure functional language
c. Haskell is a non-strict functional language
d. Haskell is a strict and pure functional language
e. All the above
f. None of the above
4) Please chooseonly ones
The type of (:) is:
a. (:) :: a -> [b] -> [c]
b. (:) :: [a] -> a -> [a]
c. (:) :: a -> [a] -> [a]
d. (:) :: [a] -> [a] -> [a]
e. All the above
f. None of the above
5) Please choosethe true ones
The type of (!!) is:
a. (!!) :: [a] -> Int -> a
b. (!!) :: a -> Int -> [a]
c. (!!) :: [a] -> Int -> Bool
d. (!!) :: [a] -> a -> Int
e. All the above
f. None of the above
6) Please choosethe true ones
The type of last is:
a. last :: a -> [a] ->a
b. last :: Int -> [a] ->a
c. last :: [a] -> a
d. last :: a -> [a]
e. all the above
f. None of them
7) Please choosethe true ones
The type of takeWhile is:
a. takeWhile :: a-> Bool -> [a] -> [a]
b. takeWhile :: (a ->Bool) -> [a] -> [a]
c. takeWhile :: (a-> Bool) -> a -> [a]
d. takeWhile :: (a ->Bool) -> [a] -> [b]
e. all the above
f. None of them
8) Please choosethe true ones
The type of replicate is:
a. replicate :: [a] ->Int -> a
b. replicate :: Int -> [a]-> a
c. replicate :: a -> Int-> [a]
d. replicate :: Int -> a ->[a]
e. all the above
f. None of them
Explanation / Answer
6) The type of last is: last :: [a] ->a
7) The type of takeWhile is:takeWhile :: (a -> Bool) -> [a] ->[a]
8) The type of replicate is:replicate :: Int -> a -> [a]
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.