Variables! — The building blocks of programming
In order for us to properly learn how to code, we have to know what Variables are.
Think of a box, a specific box that can hold a value, which we can use it instead of having to call that specific value.
There are 3 required components, with an option 4th, for us to create a Variable.

We can see that for us to create a Variable, we need to know if its either Public or Private. This means, are other scripts supposed to know of the existence of this Variable ?
Data type, which tells us what kind of box we are going to use. We can’t store heavy items in a weak box. So the data type is making sure that you are assigning the right box for the job.
Every variable has a name, otherwise, how would we know what we are going to use ? Think of it as a person in this case, how would you call people if they didn’t have a name ? Makes it easier to control everything!
And lastly we have the value of the variable itself. This is option when creating the variable, although the example has a value for each created variable.
After we have all this information set, we are good to go in using our box.
Now we can simply call the variable by name, when we need, in order to access its value.
Debug.Log(wholeNumber);
Debug.Log(_floatNumber);
Debug.Log(isRenatoRight);
Debug.Log(_myName);

Now we have all our information properly displayed on the console. Ever wondered how the game NPC always knew your name when you were speaking to him ? Its ’cause your name was stored in a variable, that is used on the text of the NPC, to chat with the player.
Lastly, when naming our variables, its a good practice to keep them in private, unless its absolutely needed to have them public.
Also, when creating a private variable, its best practice to start the variable name with a “_”, as shown in the example above.