M# Flashcards
(30 cards)
is usually declared as an array of char
C-String
declares a set of functions to
work with C style string (null terminated byte strings).
header file
copies character string from source to destination
strcpy
copies a specified bytes of characters from source to
destination.
strncpy
appends a copy of a string to the end of another string
strcat
appends a specified number of characters of a string to
the end of another string
strncat
returns length of given string
strlen
compares two null terminating string. The
comparison is done lexicographically.
strcmp
compares a specified number of characters of two
null terminating strings. The comparison is done l
exicographically.
strncmp
can be used to read a line of input
and place the string of characters on that line into a C-string
variable.
getline
allows your program to read in one character
of input and store it in a variable of type char
get function
Convert uppercase letter to lowercase
tolower
Convert lowercase letter to uppercase
toupper
Check if character is lowercase letter
islower
Check if character is alphabetic
isalpha
Check if character is decimal digit
isdigit
Check if character is alphanumeric
isalnum
Check if character is a white space
isspace
Check if character is a punctuation character
ispunct
Check if character is printable
isprint
Check if character has graphical representation
isgraph
Check if character is a control character
Isctrl
The class which provides a definition to do so is called a
String class
needs to be included in the program
to use the String class.
String header