Question
Define a function third :: [a] $\rightarrow$ a that returns the third element in a list that contains at least this many elements using:a. head and tail;b. list indexing !!;c. pattern matching.
Step 1
Using head and tail: Show more…
Show all steps
Your feedback will help us improve your experience
Goutam Chand and 63 other educators are ready to help you.
Ask a new question
Labs
Want to see this concept in action?
Explore this concept interactively to see how it behaves as you change inputs.
Key Concepts
Recommended Videos
If $f(x)=x(x-1)$ is a function from $R$ to $R$, then $\left\{x \in R / f^{-1}(x)=f(x)\right\}$ is (a) null set (b) $\{1\}$ (c) $\{0,2\}$ (d) a set containing 3 elements.
Transcript
Watch the video solution with this free unlock.
EMAIL
PASSWORD