No, that makes no sense as written. Are you sure nothing is omitted? That code uses an uninitialized variable, which can never ever work.
I think he asked if the algorithm is correct, not if the code was properly written. And it is only the initialization of the variable that is missing (which most likely is cleared and set in more than one place in the code).
That formula you have is a sort of averaging filter. Weighed average I think may be a better name for it.
Basically you have this:
smooth = ((smooth * 9) + analogRead(0))/10;
So every new sample has an effect of 10% in your signal. A little Excel sheet can do wonders to show the result of this and different weights applied to this formula.