implement functions without refernce