string.h not necessary in a C code -
i'm coding in c , realize program :
#include <stdio.h> int main(int argc, char *argv[]) { char name[100]; printf("what's name "); scanf("%s", name); printf(hi %s, nic meet !", name); return 0; }
the problem realized without string.h, program work when it's not supposed because there string. can explain me why works?
you used printf()
, scanf()
in code. both declared in stdio.h
.
"there string" not imply "string.h must included". "refer data type or function declared in string.h" does.
Comments
Post a Comment