当前位置:网站首页>Start the remedial work. Print the contents of the array using the pointer
Start the remedial work. Print the contents of the array using the pointer
2022-07-05 02:06:00 【Xiao Sun's code sharing】
Write a function to print arr Contents of array , Do not use array subscripts , Use the pointer .
arr Is an integer one-dimensional array .
#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
int main()
{
int arr[] = {1,2,3,4,5,6,7,8,9};
int* p = arr;// Defining pointer variables
int len = sizeof(arr) / sizeof(arr[0]);// Calculate the length of the array
for (int i = 0; i <len; i++)
{
printf("%d\n", *p);
++p;
}
}边栏推荐
- batchnorm. Py this file single GPU operation error solution
- Runc hang causes the kubernetes node notready
- Common bit operation skills of C speech
- Main window in QT application
- PHP Basics - detailed explanation of DES encryption and decryption in PHP
- Variables in postman
- Yolov5 model training and detection
- Security level
- Win:使用 Shadow Mode 查看远程用户的桌面会话
- 172. Zero after factorial
猜你喜欢

Yolov5 model training and detection

Mysql database | build master-slave instances of mysql-8.0 or above based on docker

Exploration and Practice of Stream Batch Integration in JD

Restful Fast Request 2022.2.1发布,支持cURL导入

Variables in postman

Kibana installation and configuration

MATLB | multi micro grid and distributed energy trading

Traditional chips and AI chips

. Net starts again happy 20th birthday

Summary and practice of knowledge map construction technology
随机推荐
Official announcement! The third cloud native programming challenge is officially launched!
R语言用logistic逻辑回归和AFRIMA、ARIMA时间序列模型预测世界人口
Main window in QT application
Collection of gmat750 wrong questions
R language uses logistic regression and afrima, ARIMA time series models to predict world population
Win:使用 PowerShell 检查无线信号的强弱
JVM - when multiple threads initialize the same class, only one thread is allowed to initialize
Win: use shadow mode to view the Desktop Session of a remote user
179. Maximum number - sort
Tucson will lose more than $400million in the next year
[机缘参悟-38]:鬼谷子-第五飞箝篇 - 警示之一:有一种杀称为“捧杀”
Yolov5 model training and detection
Open source SPL optimized report application coping endlessly
Can financial products be redeemed in advance?
Win:使用 Shadow Mode 查看远程用户的桌面会话
Phpstrom setting function annotation description
Interesting practice of robot programming 15- autoavoidobstacles
[understanding of opportunity -38]: Guiguzi - Chapter 5 flying clamp - warning one: there is a kind of killing called "killing"
【附源码】基于知识图谱的智能推荐系统-Sylvie小兔
phpstrom设置函数注释说明