Atoi function: function prototype: Intatoi (constchar * nptr);
Function: Converts a string to an integer.
Parameter nptr string. If the first non-blank character exists, it is a number or symbol, and it will start type conversion. After that, when a non-numeric character (including the terminator \0) is detected, it will stop the conversion and return an integer. Otherwise, zero is returned.
Additional code: #include? " stdio.h"#include? " stdlib.h"#include? "conio.h" is invalid? main(){char? str[ 1024]? =? {0}; int? IntergerPrintf ("Enter a number: \ n"); scanf("%s ",str); sscanf(str," %d ",& ampinter ger); Printf ("Convert to plastic: %d\n",? inter ger); getch(); }