Basic course of C language (ii) data types, variables, and operators (5)

Source: Internet
Author: User
Tags switch case

2 keywords and identifiers

3.1 Key Words
The term "keyword" is a word that has been used by the turbo C2.0 itself and cannot be used for other purposes. For example, a keyword cannot be used as a variable name, a function name, and so on.
Turbo C2.0 has the following keywords:
Turbo C2.0 Expansion of a total of 11
ASM _cs _ds _es _ss cdecl
Far near huge interrupt Pascal
A total of 32 defined by the ANSI standard
Auto double int struct break Else
Long switch case enum register typedef
char extern return Union const float
Short unsigned continue for signed void
Default goto sizeof volatile do if
While static


3.2 identifiers
Identifiers are the names of constants, variables, statement labels, and user-defined functions. The Turbo C 2.0 identifier is a very flexible definition. The following rules must be met as identifiers:
1. All identifiers must be preceded by a letter (A~z, a~z) or an underscore (_);
2. Other parts of the identifier may be composed of letters, underscores or numbers (0~9);
3. The uppercase and lowercase letters represent different meanings, i.e. they represent different identifiers;
4. Identifiers are valid only for the first 32 characters;
5. Identifiers cannot use the keywords of turbo C2.0.
Here are a few correct and incorrect identifiers:
Correct or incorrect
Smart 5smart
_decision bomb?
Key_board Key.board
float float

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.