Docs > Data Types

There are several data types in Sardonyx: - Ints, numbers with no decimal point. Examples include `-5`, `5`, and `73`. - Nums, floating point numbers. Created using `.`, for example: `5.5`, `-6.7`. - Strs, created using `"`, for example: `"abc"`, `"a"`, and `""`. - Booleans, created by writing either `true` or `false`. - Lists, which can hold any amount of any other data type, for example: `[5, 6]`, `[]`, `["a", 1]`. Lists can be indexed using `()`: `[1, 2, 3](0)` is `1`. = Nil. Nil is created using `nil`, and represents the absence of a value. Note that these types do not have concrete definitions; at present, there is no way to know the type of a value. However, several functions are provided to check if it is a particular type: `__is_int`, `__is_num`, `__is_str`, `__is_bool`, `__is_list`, and `__is_nil`. All values are first class and can be passed around. When used in `if` and `while`, values are tested for truthiness. The rules for truthiness are as follows: - Lists and strs are truthy if not empty. - The boolean `false` is not truthy. - Nil is not not truthy. - All other values are truthy.