vapply(x, FUN = length, FUN.VALUE = 0L)
#mapply
#Sums the 1st elements, the 2nd elements, etc....mapply(sum, 1:5, 1:5, 1:5)
[1] 3 6 9 12 15
#To do rep(1,4), rep(2,3), etc.
mapply(rep, 1:4, 4:1)...#Map
#A wrapper to mapply with SIMPLIFY = FALSE, so it is guaranteed to return a list.