You can ask as many times and as many questions as you want, but please do try yourself first and then ask us. It will be beneficial for you only.
int main ()
char Name, Search;
int Count = 0;
int ID, IDSearch, flag = 0;
FILE * pFile;
pFile = fopen ("myfile.txt","r"); // Enter your file-name instead of myfile.txt
while( !feof(pFile) )
fscanf (pFile, "%s %d", Search, IDSearch);
if( ! strcmp(Name, Search) )
flag = 1;
ID = IDSearch;
printf("Total %d names found in the file.\n", Count);
if( flag ) printf ("The name %s was found in\n%s %d\n", Name, Name, ID);
else printf ("The name %s was NOT found in the file !!\n", Name);
All these 3 were very easy. Are you beginning to learn C/C++ ?