added string input

creates function