-- Integer: a whole number, 64 bit
local number = 42
-- number = 42
-- Hex literal
local mb = 0x100000
-- mb = 1048576
-- A dot or an exponent makes a float
local exp = 2.71828
-- exp = 2.71828
local billion = 1e9
-- billion = 1000000000.0
-- Single and double quotes are the same
local greeting = 'Hello'
-- greeting = Hello
-- \n inside quotes, or long brackets
local text1 = "this is some\nmultiLine text"
-- text1 = this is some
-- multiLine text
local text2 = [[this is some
multiLine text]]
-- text2 = this is some
-- multiLine text
local sun_is_star = true
-- sun_is_star = true
local earth_is_star = false
-- earth_is_star = false
-- A character is a one-letter string
local char_a = "A" -- also "\65" or "\u{41}"
-- char_a = A
-- No value at all
local nothing = nil
-- nothing = nil
print("number = " .. number)
print("mb = " .. mb)
print("exp = " .. exp)
print("billion = " .. billion)
print("greeting = " .. greeting)
print("text1 = " .. text1)
print("text2 = " .. text2)
print("sun_is_star = " .. tostring(sun_is_star))
print("earth_is_star = " ..
tostring(earth_is_star))
print("char_a = " .. char_a)
print("nothing = " .. tostring(nothing))