Created input function