Random seed function added