changed variable naming and initialization