Current location - Plastic Surgery and Aesthetics Network - Plastic surgery and medical aesthetics - What are the types of constants in C language?
What are the types of constants in C language?
Generally speaking, there are two kinds, one is an integer constant and the other is a floating-point constant. In detail, integer constants also include character constants and string constants.

(1). Integer constant, such as 6,27, -299.

② Floating-point constants such as 5.43, -2.3, 5.43F (single precision) and 2.3f (lowercase f is also acceptable).

③ Character constants, such as' 6',' a' and' middle' in L'

④ string constants, such as "6", "male" and "nanabc"