added in loop
changed val age to def