当前位置:网站首页>指针相关概念
指针相关概念
2022-06-12 14:42:00 【腿毛ger】
指针是什么?
1. 指针是内存中一个最小单元的编号,也就是地址
2. 平时口语中说的指针,通常指的是指针变量,是用来存放内存地址的变量
总结:指针就是地址,口语中说的指针通常指的是指针变量。
指针变量
我们可以通过&(取地址操作符)取出变量的内存真实地址,把地址可以存放到一个变量中,这个 变量就是指针变量
指针类型
int类型指针,可操作四个字节



指针类型决定了 指针进行解引用操作的时候,能够访问空间的大小(能操作几个字节)
比如: char* 的指针解引用就只能访问一个字节,而 int* 的指针的解引用就能访问四个字节。

指针加减整数 指针的类型决定了指针向前或者向后走一步有多大(距离,字节)。
边栏推荐
- Sorting out the differences between ABS () and Fabs () in C language
- [wp][入门]攻防世界-game
- [lambda operation jcf]
- Serialization and deserialization mechanism in terms of games
- [wechat applet] 1 Introduction to wechat applet
- selenium-webdriver之断言
- Visual studio common shortcuts
- NetCore结合CAP事件总线实现分布式事务——消息(2)
- Two methods of QT using threads
- Ali suggests that all POJO attributes use wrapper classes, but have you noticed these pits?
猜你喜欢

工业机械臂(机器人)视觉定位引导系统

Reverse order of Excel
![[wechat applet] 4 Introduction to wechat developer tools](/img/9d/0d6c5cc675fb70dde98b25649bd8d8.jpg)
[wechat applet] 4 Introduction to wechat developer tools

Reverse the encryption parameters of a hot water software

C secret arts script Chapter 5 (paragraph) (Section 3)

Player practice 20 audio thread and video thread

ADB command (2) use monkey to test

Analysis of two-dimensional array passing as function parameter (C language)

Two methods of QT using threads

面向优化科学研究领域的软件包
随机推荐
Soft test (VI) Chrome browser installation selenium IDE
华为设备配置H虚拟专用网
[wechat applet] 2 Environmental preparation
MAT的安装和使用
亿纬锂能拟募资90亿:刘金成骆锦红夫妇合计认购60亿 布局光谷
webdriver入门
Basic usage of scanner
Webdriver opens in full screen and a prompt "Chrome is under the control of automatic test software" appears in Chrome
阿里建议所有 POJO 类属性使用包装类,但这些坑你有注意到吗?
Software package for optimization scientific research field
Crawler problem set (I) record
Visual studio common shortcuts
程序构造和解释之过程抽象
PMP agile knowledge points
【Calendar】1. For globalization 2 But only date can be formatted by SDF 3 Month to -1 4 Week from Sunday is the first day
Player practice 19 xaudio turn on audio
The igatewayloadbalancer interface implements routing. Otherwise, it follows Sid routing
Chapter I exercises of program construction and interpretation
ADB command (I) record
面向优化科学研究领域的软件包