Thursday, 19 January 2012

What is a variable ?

'int" is a number. stands for intriguer (whole number)
You give the number a name. (holder for the number) e.g 'analog pin' then you say what the number is = to. (analog number on the arduino)
because you have the number if you have to change the anlog number at anytime you only have to change it once, because you have named it.
When you make a variable you say what variable type by naming it then can use it in the way it is ment to be used.

Val- the number of the value of the sensor.
// -  then this sign is shown on the code, it just means that you can write a comment for people can read but the computer doest read it.


No comments:

Post a Comment