. 1 #include <the cmath> 2 trigonometric functions cos (radians) or cos (degrees * 3.1415926 / 180 ) 3 inverse trigonometric function prototype for Double ASIN ( Double X); . 4 Gaussian function (floor function) floor (x) ; returns the largest integer not exceeding x int m = Floor (sqrt (n-) + 0.5 ); improve the accuracy of 5 rounded up function ceil (x); the smallest integer larger than x . 6 #include <time.h> . 7 Clock ( ); in seconds: ( Double ) Clock () / CLOCKS_PER_SEC; . 8 #include <string.h> . 9 copy int k-th element of the array to the memcpy a array B (B, a, the sizeof ( int ) * k); 10Copy the k double elements from the array a to the array b the memcpy (b, a, the sizeof ( double ) * k); . 11 put array a copied to the array b, the memcpy (b, a, the sizeof (a)); 12 is Memset ( buf, 0 , sizeof (buf)); initialization 13 to find the location strchr (array name, character) the first occurrence of the string of characters; to find the find the location of the pointer is returned, not found it returns NULL 14 returns an array of characters actually length strlen (buf); return completion flag \ until the number of characters 0 15 string copy functions strcpy (a, B); 16 string comparison function strcmp (a, B); . 17 string concatenation function strcat (a, b ); 18 is #include <algorithm> . 19 lower_bound () tries to find an element in the sorted value of [first, last) in the. Returns an iterator, points to the first "not less than value" elements, 20 If the value is greater than any element [First, last) in the, last is returned. Indeed, it returns "in sequence without breaking, can be inserted into a first place of value." 21 upper_bound () value in trying to find the elements sorted [first, last) in. It returns an iterator, 22 if the value exists, the iterator will point to a final value of the next position. In fact, it will return "without destruction sequence, can be inserted into a suitable location value of the last." 23 can also be understood as a first element is greater than the value of the position (last does not exist is returned). 24 binary_search () returns a value of type Bool, has an element equivalent to the value if the [first, last), will return to true , otherwise to false . 25 #include <stdio.h> 26 is e.g. sprintf (buf, " % D%% D D D% D% " , ABC, de, X, Y, Z); buf is the output string array to the name string must is char buf [], can then be buf [I] - ' 0 ' to obtain values 27 getchar (); characters read, returns the read character code ASCALL value or the EOF, white spaces and can be swallowed 28 #include <ctype.h> 29 the isalpha (); determined character is a letter 30 #include <String> 31 is the istream & getline (the istream & IS , String & STR, char the delim) and the istream & getline (the istream & IS , String & STR) 32 #include <the iostream> 33 is the istream & getline ( char * S, streamsize n-) and the istream & getline ( char * S, n-streamsize, char the delim); Note that the read character string is stored in the array char without the parameters may be declared as type string 34 is #include <stdlib.h> 35int atoi (const char * p) ; the string is converted into digital values using an exemplary shaping: z.push (atoi (p)) ; push integer into a string
36 eg: char a [] = "- 100 "; the atoi (a) equal to -100 char B [] =" +123 "; the atoi (b) equals 123 char C [] =" 123 "; the atoi (c) equal 123