TYL PROGRAMMING LANGUAGE
▶ ACCESS & EDIT RECORDS
Accessing Record Keys
Throughout this chapter we'll use the product record:
product { cat 'Electrical' name 'LED Light Bulb' }
product record has two properties in its mapping data. If a record has non empty mapping data, each key can be accessed in the static style, also knowm as dot notation:
product.name
Static keys are essentialy a property of a record, and the terms key and property, will be used here interchangeably.

Alternatively it can or otherwise should be accessed in the dynamic style:
product 'name'
In line product 'name', we access the name property of product record dynamically without the dot notation.

This enables us to use a scalar value or even a whole statement for the record key:
print product 'cat'
Electrical
product 'cat' value was printed.

Using a scalar:
key 'cat'
print product key
One case that it isn't possible to use dot notation, is when record key contains space characters:
shape { 'shape name' 'Circle' 'shape area' 127.32 }
print shape 'shape name'
Circle
An example of a system record is the now system function:
print now
{
 year: 2021
 month: 10
 day: 4
 hour: 7
 minute: 3
 second: 27
 millisecond: 86
 totalsecond: 111807.0868695
 weekday: 1
 yearday: 277
 fulldate: '2021-10-04 07:03:27.086'
}
Whenever now system function is called, it returns a record value with the current time. Unlike record variables that can be used to access their properties, to access now properties, you must assign it to another predefined record variable.
PART 1
PART 3