Linux C function library reference

Source: Internet
Author: User
Tags random seed

Asctime (represents the time and date in string format)
Clock (obtain the CPU usage time of the process)
Ctime (Representation of time and date in string format)
Difftime (computing time gap)
Ftime (get the current time and date)
Gettimeofday (get current time)
Gmtime (get the current time and date)
Localtime (obtain the current local time and date)
Mktime (the number of seconds after the time structure data is converted)
Settimeofday (set the current time)
Strftime (format Date and Time)
Time (obtain the current time)
Tzset (set the time zone for time conversion)

 

ABS (calculate the absolute value of an integer)
ACOs (returns the arccosine function value)
Asin (returns the arcsin function value)
Atan (returns the arc tangent function value)
Atan2 (obtain the arctangent function value)
Ceil (minimum integer value not less than the parameter)
Cos (cosine function value)
Cosh (returns the hyperbolic cosine function value)
Div (the quotient and remainder after the division of Two integer values)
Exp (computing index)
FABS (calculate the absolute value of floating point type)
Frexp (float data is divided into base data and indexes)
Hypot)
Labs (calculate the absolute value of a long integer)
Ldexp (calculate the power of 2)
Ldiv (obtain the quotient and remainder after division of two long integers)
Log (calculate the logarithm value based on E)
Log10 (calculate the base-10 logarithm value)
MODF (splits floating point numbers into integers and decimals)
Pow (calculate power)
Sin (sine function value)
Sinh (returns the hyperbolic sine function value)
SQRT (calculate the square root value)
Tan (returns the tangent function value)
Tanh (returns the hyperbolic tangent function value)

 

Crypt (password or data encoding)
Getpass (get a password)

 

Drand48 (generate a positive floating point random number)
Erand48 (generate a positive floating point random number)
Initstate (create an array of random number states)
Jrand48 (generates a long integer random number)
Lcong48 (set the seed of the random number of the 48-bit operation)
Lrand48 (generate a positive long integer random number)
Mrand48 (generate a long integer random number)
Nrand48 (generate a positive long integer random number)
Rand (Random Number Generation)
Random (Random Number Generation)
Seed48 (seed48 random number seed)
Setstate (create a random number status array)
Srand (set Random Seed)
Srand48 (set the seed of the random number of the 48-bit operation)
Srandom (set Random Seed)

 

Clearerr (error flag for clearing file streams)
Fclose (close file)
Fdopen (convert file description to file pointer)
Feof (check whether the file stream has read the end Of the file)
Fflush (update buffer)
Fgetc (one character read from the file)
Fgetpos (get the reading location of the file stream)
Fgets (read a string from the file)
Fileno (returns the file description used by the file Stream)
Fopen (open a file)
Fputc (write a specified character to the file Stream)
Fputs (write a specified string into the file)
Fread (reads data from a file Stream)
Freopen (open a file)
Fseek (read/write location of a mobile file Stream)
Fsetpos (read/write location of a mobile file Stream)
Ftell (get the reading location of the file stream)
Fwrite (write data to a file Stream)
GETC (one character read from the file)
Getchar (reads one character from the standard input device)
Gets (reads a string from the standard input device)
Mktemp (generate a unique temporary file name)
Putc (write a specified character to the file)
Putchar (write specified characters to the standard output device)
Puts (write the specified string to the standard output device)
Rewind (resetting the file stream's read/write position to start with the file)
Setbuf (set the buffer of the file Stream)
Setbuffer (set the buffer of the file Stream)
Setlinebuf (set the file stream as a linear buffer)
Setvbuf (set the buffer of the file Stream)
Tmpfile (create a temporary file)
Ungetc (write a specified character back to the file Stream)

 

Fprintf (format the output data to a file)
Fscanf (Format String input)
Printf (format output data)
Scanf (Format String input)
Snprintf (format string copy)
Sprintf (format string copy)
Sscanf (Format String input)
Vfprintf (format the output data to a file)
Vfcanf (Format String input)
Vprintf (format output data)
Vscanf (Format String input)
Vsnprintf (format string copy)
Vsprintf (format string copy)
Vsscanf (Format String input)

 

Alarm)
Kill (send a signal to a specified process)
Pause (pause the process until the signal appears)
Psignal (list signal descriptions and specified strings)
Raise (send a signal to the current process)
Sigaction (query or set the signal processing method)
Sigaddset (add a signal to the signal set)
Sigdelset (delete a signal from the signal set)
Sigemptyset (initialize Signal Set)
Sigfillset (add all signals to the signal set)
Sigismember (test whether a signal has been added to the signal set)
Signal (set Signal Processing Method)
Sigpause (pause until the signal arrives)
Sigpending (query signals shelved)
Sigprocmask (query or set the signal mask)
Sigsuspend (pause until the signal arrives)
Sleep (pause the process for a period of time)
Isdigit (test whether the character is Arabic numerals)

 

Mkfifo (create a named pipe)
Pclose (disable pipeline I/O)
Pipe (pipeline creation)
Popen (create pipeline I/O)

 

Ftok (convert the file path and plan code to systemcvipckey)
Msgctl (controls the operation of information queues)
Msgget (create an information queue)
Msgrcv (read information from the information queue)
Msgsnd (send information to the information queue)
Semctl (control signal queue operations)
Semget (configure the signal Queue)
Semop (Signal Processing)
Shmat (attach shared memory)
Shmctl (controls shared memory operations)
Shmdt (detach shared memory)
Shmget (configure shared memory)

 

Getenv (get environment variable content)
Putenv (change or add environment variables)
Setenv (change or add environment variables)
Unsetenv (clear environment variable content)

 

Dlclose (close the dynamic function library file)
Dlerror (Dynamic Function error handling)
Dlopen (open the dynamic function library file)
Dlsym (search for dynamic functions from shared objects)
Chapter 2 Other Functions
Getopt (analyze command line parameters)
Isatty (determine whether the file description is a terminal)
Select (I/O multi-work mechanism)
Ttyname (return the name of a terminal)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.