CCTYPE Function Series, cctype Function

Source: Internet
Author: User
Tags uppercase character

CCTYPE Function Series, cctype Function
# Include <cctype> Functions

In c ++, it should be # include <cctype>

In c, it should be # include <ctype. h>

The following are common functions in the character function library:

 

Function Name Return Value
Isalnum () If the parameter is a letter or number, this function returns true.
Isalpha () If the parameter is a letter, this function returns true
Isblank () If the parameter is a space or horizontal tab, this function returns true.
Iscntrl () If the parameter is a control character, this function returns true
Isdigit () If the parameter is a number (0 ~ 9). This function returns true.
Isgraph () If the parameter is a print character other than space, this function returns true
Islower () If the parameter is a lowercase letter, this function returns true.
Isprint () If the parameter is a print character (including spaces), this function returns true
Ispunct () If the parameter is a punctuation mark, this function returns true.
Isspace ()

If the parameter is a standard blank character, such as space, paper feed, line feed, and carriage return

, Horizontal or vertical tab, this function returns true

Isupper () If the parameter is an uppercase letter, this function returns true.
Isxdigit () If the parameter is a hexadecimal number, that is, 0 ~ 9. ~ F, ~ F. This function returns true.
Tolower () If the parameter is an uppercase character, it is returned in lower case; otherwise, this parameter is returned.
Toupper () If the parameter is a lowercase letter, it is returned in uppercase; otherwise, this parameter is returned.

 

 

 

Commonly used:

Tolower () -- toupper ()

Isupper () -- islower ()

Isalnum () -- isalpha ()

Related Article

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.