another 'gotcha' is MOST programming languages is:
= means assignment
ie: var x = 2;
== means conditional check
ie: if( x == 2){ //execute if true, if x equals 2};
dont feel bad! I have a web programming background.. (spoiled)... and I still have difficulty with the data types what is best to use when/why...etc