🍔Quiz
Question 1 - ⏱ 10’’
type Address = { City: string; Country: string }
let format address = $"{address.City}, {address.Country}"
let addresses: Address list = ...
What function should you use to apply the format
function to addresses
?
A. List.iter()
B. List.map()
C. List.sum()
Question 2 - ⏱ 10’’
Que vaut [1..4] |> List.head
?
A. [2; 3; 4]
B. 1
C. 4
Question 3 - ⏱ 10’’
Quelle est la bonne manière d'obtenir la moyenne d'une liste ?
A. [2; 4] |> List.average
B. [2; 4] |> List.avg
C. [2.0; 4.0] |> List.average
Last updated
Was this helpful?