Guest User

Untitled

a guest
Jan 23rd, 2018
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.19 KB | None | 0 0
  1. int my_getnbr(char *str)
  2. {
  3. int out;
  4.  
  5. out = 0;
  6. while (*str >= '0' && *str <= '9')
  7. {
  8. out *= 10;
  9. out += *str - '0';
  10. str += 1;
  11. }
  12. return (out);
  13. }
Add Comment
Please, Sign In to add comment