C programming notes batracomputercentre

Page 10

Basic Building Blocks and Definition : Token

Meaning

Keyword

A variable is a meaningful name of data storage location in computer memory. When using a variable you refer to memory address of computer

Constant

Constants are expressions with a fixed value

Identifier

The term identifier is usually used for variable names

String

Sequence of characters

Special

Symbols other than the Alphabets and Digits and white-spaces

Operators A symbol that represent a specific mathematical or non mathematical action

  

C Constants are also like normal variables. But, only difference is, their values can not be modified by the program once they are defined. Constants refer to fixed values. They are also called as literals Constants may be belonging to any of the data type.

Syntax:

const data_type variable_name; (or) const data_type *variable_name; Types of C constant: 1. 2. 3. 4. 5. 6.

Integer constants Real or Floating point constants Octal & Hexadecimal constants Character constants String constants Backslash character constants


Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.