当前位置:网站首页>C constant, cannot be changed
C constant, cannot be changed
2022-06-12 14:51:00 【Leg hair Ger】
C In language, constants are divided into
1 Literal constants
2 const Modified constant variable
3 #define Defined identifier constant
4 Enumeration constants
// In brackets MALE,FEMALE,SECRET It's an enumeration constant
enum Sex {
MALE,
FEMALE,
SECRET
};
The default of enumeration constants is from 0 Start , Increase in descending order 1 Of namely 0 1 2
// Literal constants
3.14;// Literal constants 1000;// Literal constants
//const Modified constant variable
const float pai = 3.14f; // there pai yes const Modified constant variable ,
stay C In language, variables are limited only at the grammatical level pai Can't be changed directly , however pai Is essentially a variable , So it's called a constant variable .
pai = 5.14;// It can't be modified directly !
//#define The identifier constant for
#define MAX 100
边栏推荐
- 亿纬锂能拟募资90亿:刘金成骆锦红夫妇合计认购60亿 布局光谷
- ES6新特性
- Leader education was forced to be delisted: Softbank CMC suffered heavy losses only one year after listing
- 面向优化科学研究领域的软件包
- [gatewaysessioninactiveevent event] 1 Connect your own client disconnect
- Array one
- Module VIII
- Mobileone: the mobile terminal only needs 1ms of high-performance backbone. You deserve it!
- Software package for optimization scientific research field
- 掌门教育被强制退市:上市仅一年时间 软银CMC损失惨重
猜你喜欢

Unit test (I) unit test with JUnit

Jetpack architecture component learning (3) -- activity results API usage
![[wp][入门]攻防世界-game](/img/07/1ea54d14ba3caca25a68786d5be4a6.png)
[wp][入门]攻防世界-game

PMP agile knowledge points

掌门教育被强制退市:上市仅一年时间 软银CMC损失惨重

sql跨库注入

NetCore结合CAP事件总线实现分布式事务——入门(1)

Data collection

New technology: efficient self-monitoring visual pre training, local occlusion no longer need to worry!
![[wechat applet] 1 Introduction to wechat applet](/img/7c/6e62269438a0dd7e7172cb37af9fb9.jpg)
[wechat applet] 1 Introduction to wechat applet
随机推荐
新技术:高效的自监督视觉预训练,局部遮挡再也不用担心!
Unit test (I) unit test with JUnit
Raspberry pie get temperature and send pictures to email
selenium-webdriver之断言
C 转义字符
sql跨库注入
ADB command (2) use monkey to test
Machine learning learning notes
阿里建议所有 POJO 类属性使用包装类,但这些坑你有注意到吗?
【LDA】EM变分推理 粗略版笔记【待完善
Jetpack architecture component learning (3) -- activity results API usage
Energy chain smart electronics landed on NASDAQ: Bain is the shareholder to become the first share of charging services in China
Process abstraction of program construction and interpretation
win10_ Home Edition cannot use remote desktop, and can be accessed by remote desktop.
启明智显分享| 2.8寸手持中控屏应用方案
[spark][core] interview questions talk about push based shuffle
面向优化科学研究领域的软件包
Common assertions in JUnit testing
Assertion of selenium webdriver
C magic skill Chapter 4 (detailed explanation of memory function)