A comment is used to tell the computer that some text is a note for the developer and the code should not be executed.
A boolean can be
A number can be any number.
A string is a collection of characters.
An array is a special data type that can store multiple values of different data types.
An object is a bunch of primitive values put together to make a new data type.
A function allows the programmer to abstract some code and run it somewhere else.
In typescript, you can declare a new variable using
Below are some of the most commonly used built-in operators.
A function consists of two main parts, the function parameters, and the function body.
After the programmer writes the code they want in the function body. They can specify what should be returned from the function using the return keyword.
Call a function
To call a function you can use the function name followed by
Get the results of a function
Because engineers work with strings of characters a lot, typescript makes it easy to compose them together with string interpolation.
number (numeric value)
string (a collection of characters)
array (many values)
boolean (true of false)
any (any type)
In typescript, many types will be inferred by the system. Meaning you don't have to explicitly write them out. You can create your own types using the interface keyword.