Created get input function