My declaration of a variable not working properly

I know I don't have to declare the variable in this first line, but I would still like to know why it doesn't work. I thought it would be a float variable and I wanted to be proper and all and declare it right off the bat. But I get an error that says "invalid redeclaration of variable." How should the first line be written then when I declare the variable.

Here is the script:

float $pointTemp;
$pointTemp = pointPosition;
polyCube;
move -a $pointTemp[0] $pointTemp[1] $pointTemp[2];

Well it looks to me like you need to decalre a vector since that is the output from pointPosition

or maybe try: float $pointTemp[]; --a float array

Since it's saying your "redeclaring", it usually means you are working in the Script Editor and have already told Maya that this particular variable is a different type (i.e. other than float), and now you changed it to a float, and it doesn't like it because it thinks it's still whatever you first said.

Try renaming the variable and see if that works.

-bN

in future write code in script editor inside {} so that the variables get killed on end of execution if not needed!