Number of items
count x count[x]
Where x is
q)count 0 / atom
1
q)count "zero" / vector
4
q)count (2;3 5;"eight") / mixed list
3
q)count each (2;3 5;"eight")
1 2 5
q)count `a`b`c!2 3 5 / dictionary
3
q)/ the items of a table are its rows
q)count ([]city:`London`Paris`Berlin; country:`England`France`Germany)
3
q)count each ([]city:`London`Paris`Berlin; country:`England`France`Germany)
2 2 2
q)count ({x+y})
1
q)count (+/)
1