working without objects