Since this is more like a learning question, I will try to give some advice, not a complete answer.
GetType ( ) , , . , , , :
match a with
| Litre(n) -> // Do something with 'n'
// Add all the other cases here
, , , - , - , , , , .
let rec sumSameTypes (list:volume list) : float * float * float * float =
match list with
| [] ->
0.0, 0.0, 0.0, 0.0
| x::xs ->
, , . , - ( ), , :
type Unit = Litre | Galon | Bushel | Bucket
type Volume = { Amount : float; Unit : Unit }
, Map<Unit, float> .