Amdocs interview question

He asked me to write a code to convert a string to float integer.