The built-in function len returns the number of elements in a map:
len
map
https://codeeval.dev/gist/eb405783993a6efab3d0bf4ead476e4d
A nil map has size 0:
nil
https://codeeval.dev/gist/5a372359868c4e8cb5aba92732e153ce