Meta interview question

Writing a function to convert an input string into integer.