Converted all explicit type declarations to use the 'var' keyword