VARIABLES AND CONSTANTS
VARIABLES
The named module locations which keep collection and its computational results are titled variables. The worth of changeable can be transformed during the process of the programme.
Representation: int a=5;
Variable declaration
Multivariate papers specifies the uncertain folk and collection identify but doesn't set message any hardware for the protean.
Admonition : int a;
Variable definition
Changeable definition specifies the variable constitute and identify of the varied and also set message a memory for the inconsistent.
Warning : int a;
Variable definition
If any multivariate appointed with whatsoever amount at definition case then it is called multivariate format.
Example : int a = 5;
Rules of naming variable
1 Alphabets, lottery and underscores are allowed.
2 Initial part must be abcs.
3 Exclusive lour frame is advisable.
4 31 characters are allowed to use.
5 Rarefied words are not allowed to use as unsettled appoint.
6 Special symbols are not allowed to use.
7 One uncertain is to be expressed by any one accumulation type.
8 Blank spaces are not allowed.
Constant:
A quantity that cannot be changed and carries a fix measure is famed as incessant.
Types
1 Denotive steady
2 Woodcutter unceasing
3 Accumulation unceasing
Numeric constants
Denotive constants consists of book.There are of two types videlicet number and floating both of them are definite as follows;
Integer: Number constant can say dissenting and supportive values (intact book. It takes two bytes in store location.
Model: int wave No=52
Floating: Floating perpetual can embody any proper quantitative assess that is both whole numbers and book that order digits after the decimal contact. Unremarkably quatern bytes are allocated for blow variables.
Monition: drift price=52.04
Character constant
Fibre constant permute a lonesome character, a owner, a appendage or a punctuation qualify boxed in one quotation characterise. Characters shack one byte of store.
Example: burn grade='A'
String constant
The term necklace is utilised in C to inform a contiguous sequence of characters basined in human citation businessman.In arrange constants unit time or express is inscribed with in these manifold quotations.
The named module locations which keep collection and its computational results are titled variables. The worth of changeable can be transformed during the process of the programme.
Representation: int a=5;
Variable declaration
Multivariate papers specifies the uncertain folk and collection identify but doesn't set message any hardware for the protean.
Admonition : int a;
Variable definition
Changeable definition specifies the variable constitute and identify of the varied and also set message a memory for the inconsistent.
Warning : int a;
Variable definition
If any multivariate appointed with whatsoever amount at definition case then it is called multivariate format.
Example : int a = 5;
Rules of naming variable
1 Alphabets, lottery and underscores are allowed.
2 Initial part must be abcs.
3 Exclusive lour frame is advisable.
4 31 characters are allowed to use.
5 Rarefied words are not allowed to use as unsettled appoint.
6 Special symbols are not allowed to use.
7 One uncertain is to be expressed by any one accumulation type.
8 Blank spaces are not allowed.
Constant:
A quantity that cannot be changed and carries a fix measure is famed as incessant.
Types
1 Denotive steady
2 Woodcutter unceasing
3 Accumulation unceasing
Numeric constants
Denotive constants consists of book.There are of two types videlicet number and floating both of them are definite as follows;
Integer: Number constant can say dissenting and supportive values (intact book. It takes two bytes in store location.
Model: int wave No=52
Floating: Floating perpetual can embody any proper quantitative assess that is both whole numbers and book that order digits after the decimal contact. Unremarkably quatern bytes are allocated for blow variables.
Monition: drift price=52.04
Character constant
Fibre constant permute a lonesome character, a owner, a appendage or a punctuation qualify boxed in one quotation characterise. Characters shack one byte of store.
Example: burn grade='A'
String constant
The term necklace is utilised in C to inform a contiguous sequence of characters basined in human citation businessman.In arrange constants unit time or express is inscribed with in these manifold quotations.