It seems that using a global variable by adding $ before the 'a' 
variable name solve the problem.
-- 
Posted via http://www.ruby-forum.com/.