added a number variable and changed variable names to be more appropriately named