c - 使用指针传递二维数组
问题描述
解决方案
It is possible to use pointers for 2D arrays. char **
doesn't represent a 2D array - it would be an array of pointers to pointers. This is how you would pass a 2D char array to a function printarray
.
void printarray( char (*array)[50], int SIZE )
推荐阅读
- c# - 如何在 txt 文件中的名称列表中添加新名称,然后添加所有名称并在字符串中显示该数量的名称
- angular - 我应该如何将 v5 中管道中使用的合并转换为 v6
- r - 从公司的每日回报中寻找每周回报
- azure - 如何将用户特定文件存储在 blob 容器中
- powerbi - ODBC:错误 [HY000] [Microsoft][DriverSupport] (1170)
- templates - 鹡鸰中未读取模板
- c# - System.Collections.Immutable.dll 正在从 Microsoft.Net.Compilers 包中替换
- linux-kernel - 从 GRUB 菜单项运行脚本
- weblogic - 为什么除了争用之外还有卡住的线程,比如慢 IO、慢后端(DB 查询、Web 服务、rmi 调用)?
- excel - 如何将字符串名称更改为特定的字符串名称?