type¶
Type of an object
type x    type[x]Where x is any object, returns its type.
The type is a short int:
- zero for a general list
- negative for atoms of basic datatypes
- positive for everything else
q)type 5                        / integer atom
-7h
q)type 2 3 5                    / integer vector
7h
q)type (2 3 5;"hello")          / general list
0h
q)type ()                       / general list
0h
q)type each (2;3 5;"hello")     / int atom; int vector; string
-7 7 10h
q)type (+)                      / function
102h
q)type (0|+)                    / composition
105h