實現將一個字符串轉化成對應的整形數字

輸入一個字符串好比「+1234」,將其轉換成對應的數字1234輸出,如果「-1234」,則輸出-1234:ide #include <stdio.h> enum Charec{TRUE,FALSE}; int check = FALSE; int my_atoi(const char *str) {  int num = 0;  if((str != NULL)&&(*str != '\0'))
相關文章
相關標籤/搜索