社区
C语言
帖子详情
how to resolve the question?
msgsnd
2004-06-10 02:04:57
int *test(){
int *a=NULL;
a=malloc(sizeof(a));
*a=200;
return a;
}
void main(){
int *a=NULL;
int b=0;
a=test();
b=(*a)++;
printf("%d",a);
free(a);
}
...全文
87
2
打赏
收藏
how to resolve the question?
int *test(){ int *a=NULL; a=malloc(sizeof(a)); *a=200; return a; } void main(){ int *a=NULL; int b=0; a=test(); b=(*a)++; printf("%d",a); free(a); }
复制链接
扫一扫
分享
转发到动态
举报
写回复
配置赞助广告
用AI写文章
2 条
回复
切换为时间正序
请发表友善的回复…
发表回复
打赏红包
leonchew
2004-06-10
打赏
举报
回复
//你可能是这个意思吧
#include <stdio.h>
int *test(){
int *a=NULL;
a=(int*)malloc(sizeof(a));//加强制类型转换int*
*a=200;
return a;
}
void main(){
int *a=NULL;
int b=0;
a=test();
b=++(*a);// ++ 在前面,b才能是 *a+1了,否则 结果是200
printf("%d\n",b);//是 b
free(a);
return;
}
结果: 201
junnyfeng
2004-06-10
打赏
举报
回复
有什么问题
PCODA2005proceedings.pdf
Complex software is often constructed with the help of complex and sometimes generative build processes, automated with the help of various scripting and incremental development tools. Many dynamic analysis techni
que
s require instrumentation of source code to extract runtime information. Automated transformation systems can be used to insert this instrumentation, but this is typically a separate process that is applied to source files prior to system builds. In cases where the build processes actually construct source files, or determine which source files out of a source base, or in cases where the instrumentation process is aided by configuration information that may not be known until mid-build, the
que
stio
n of what code should be instrumented and how may be difficult or impossible to
resolve
prior to the build. Moreover, build processes may be rather opa
que
to quality assurance responsible for instrumentation. Instrumenting source code in midbuild, for example immediately before module compilation, offers a way to deal with these complexities
PCODA2005proceedings.7z.002
Complex software is often constructed with the help of complex and sometimes generative build processes, automated with the help of various scripting and incremental development tools. Many dynamic analysis techni
que
s require instrumentation of source code to extract runtime information. Automated transformation systems can be used to insert this instrumentation, but this is typically a separate process that is applied to source files prior to system builds. In cases where the build processes actually construct source files, or determine which source files out of a source base, or in cases where the instrumentation process is aided by configuration information that may not be known until mid-build, the
que
stio
n of what code should be instrumented and how may be difficult or impossible to
resolve
prior to the build. Moreover, build processes may be rather opa
que
to quality assurance responsible for instrumentation. Instrumenting source code in midbuild, for example immediately before module compilation, offers a way to deal with these complexities
现代大学英语精读第二版(第六册)学习笔记(原文及全文翻译)——7 - How to Get the Poor off Our Conscience(怎样不为穷人的存在感到内疚)
Unit 7 -How to Get the Poor off Our Conscience How to Get the Poor off Our Conscience John Kenneth Galbraith I would like to reflect on one of the oldest of human exercises, the process by which over the years, and indeed over the centuries, we have un.
How to install software in Ubuntu?
we will learn how to install software in ubuntu from the process of installing python3.7.4. There are three ways : Using the command “apt” directly; Downloading a .tgz software package from its offic...
git_ask_00-From SVN to Git
文章目录
Que
stio
nAnswerStep1: Create project in GithubStep2: CheckoutStep3: UpdateStep4: Add changes to IndexStep5: CommitStep6: Conflict
resolve
manuallyStep7: Push to serverQ&AQ1. git Bash Here?Q2. How to add folder?Q3. How to show log?Q4. How to compare?
C语言
70,039
社区成员
243,246
社区内容
发帖
与我相关
我的任务
C语言
C语言相关问题讨论
复制链接
扫一扫
分享
社区描述
C语言相关问题讨论
社区管理员
加入社区
获取链接或二维码
近7日
近30日
至今
加载中
查看更多榜单
社区公告
暂无公告
试试用AI创作助手写篇文章吧
+ 用AI写文章