pointer in c

  • The function getenv () in C The function getenv () in C char * getenv (const char * name) function searches the environment string pointed to by the name parameter and returns the value associated with that string.
  • System () function in C System () function in C the int system (const char * command) function passes the command name or program name specified by the command to the host environment to be executed by the command processor and returned after the command is completed.
  • The function bsearch () in C The function bsearch () in C void function * bsearch (const void * key, const void * base, nitems, size, int (* compar) (const void *, const void *)) looks for an array of nitems objects, its original member is point to by base, for a member that connects the object pointed to by the key. the size of each array element is
  • Function abs () in C Function abs () in C the function int abs (int x) returns the absolute value of integer x.
  • Div () function in C Div () function in C div_t div function (int numer, int denom) divides numer numerator for denom.
  • Labs () function in C Labs () function in C function long int labs (long int x) returns the absolute value of x.
  • The function rand () in C The function rand () in C the function int rand (void) returns a random number in the range from 0 to rand_max.
  • Calloc () function in C Calloc () function in C the function void * calloc (so-phan-tu, kich-co-phan-tu) allocates the requested memory and returns a pointer to it. the difference between malloc and calloc is: malloc does not set memory to 0 while calloc sets the allocated memory to 0.
  • Free () function in C Free () function in C the void free function (void * ptr) frees the previously allocated memory by a call to calloc, malloc, or realloc
  • Malloc () function in C Malloc () function in C the malloc () function allocates the requested memory and returns a pointer to it.
  • Function realloc () in C Function realloc () in C the realloc () function attempts to recover the memory block pointed to by the ptr pointer that was previously allocated with a call to malloc or calloc.
  • The abort () function in C The abort () function in C the abort () function stops executing the program abnormally.