Loading...
C++

Constants

Constants refer to fixed values that the program may not alter. Constants can be of any of the basic data type. The way each constant is represented depends upon its type. Constants are also called literals. Constant uses the secondary storage area.
In C++ constants are of two types:

1.Numeric Constant
2.Non-Numeric Constant (Character Constant)

1.Numeric Constant:

These have numeric value having combination of sequence of digits i.e. from 0-9 as alone digit or combination of 0-9 with or without decimal point having either positive or negative sign.
TheseĀ  are sub divided into two categories. They are:
i) Integer Numeric Constant
ii) Float or Real Numeric Constant

i) Integer Numeric Constant:

Leave a Reply

Your email address will not be published. Required fields are marked *