to answer your question about floats (and other variables at the same time too i guess), you can name a float type variable anything you want (almost) but it's value has to be a number with a decimal place, for example, you could have this:
Code:
#include <iostream>
using namespace std;
int main()
{
float the_float = 13.4;
cout<<the_float;
int a_number = 4; //etc. same with other variables
cout<<a_number;
return 0;
}
But you couldn't have this:
Code:
int main()
{
float a_float = "this is a float"; //Because a_float has to
int a_number = "this is a number"; //equal a number with a
return 0; //decimal point.
}
/*It's the same with any other variable, it can be called almost anything, but it has to equal it's type, ie. an int has to equal a number, a char has to equal a character (unless it's a string, but don't worry about that yet) */
Edit: Woah sorry my post stretched out so far to the right, but I don't know how to fix it.