一个[++ j]的一个= [j]的一个+ [J + 1]; [英] a[++j]=a[j]+a[j+1];
问题描述
该怎么办
int pto(void)
{int a [50] = {0};
a [0] = 1;一个[1] = 2;一个[2] = 3; a [3] = 4;
j = 0;
a [++ j] = a [j] + a [j + 1];
返回[j-1];
}
什么是返回值?
谢谢你
RSoIsCaIrLiIoA写道:应该做什么
int pto(void)
{int a [50] = {0};
a [0] = 1;一个[1] = 2;一个[2] = 3; a [3] = 4;
j = 0;
a [++ j] = a [j] + a [j + 1];
返回[j-1];
}
什么是返回值?
谢谢你
一个整数;)
如果你分享你的答案我会分享我的答案。
RSoIsCaIrLiIoA写道:应该是什么做什么
int pto(void)
{int a [50] = {0};
a [0] = 1;一个[1] = 2;一个[2] = 3; a [3] = 4;
j = 0;
a [++ j] = a [j] + a [j + 1];
返回[j-1];
}
什么是返回值?
未定义,请参阅类似示例:
http://www.eskimo.com/~scs/c-faq.com...valorder1.html
西城
谢谢你
RSoIsCaIrLiIoA写道:< blockquote class =post_quotes>应该做什么
int pto(void)
{int a [50] = {0};
a [ 0] = 1;一个[1] = 2;一个[2] = 3; a [3] = 4;
j = 0;
a [++ j] = a [j] + a [j + 1];
返回[j-1];
}
什么是返回值?
这可能是一个有用的链接:
< a rel =nofollowhref =http://groups.google.com/group/microsoft.public.vc.language/browse_thread/thread/a4dc7192f5ef7f60/f3c4d4d9039ea004?q=%22Function+call+evaluation+order%22& rnum = 1#f3c4d4d9039ea004target =_ blank> http://groups.google.com/group/micro...c4d4d9039ea004
Abdo Haji-Ali < br $>
程序员
In | Framez
what is supposed to do
int pto(void)
{int a[50]={0};
a[0]=1; a[1]=2; a[2]=3; a[3]=4;
j=0;
a[++j]=a[j]+a[j+1];
return a[j-1];
}
what will be the return value?
thank U
RSoIsCaIrLiIoA wrote:what is supposed to do
int pto(void)
{int a[50]={0};
a[0]=1; a[1]=2; a[2]=3; a[3]=4;
j=0;
a[++j]=a[j]+a[j+1];
return a[j-1];
}
what will be the return value?
thank U
An integer ;)
I''ll share my answer if you share yours.
RSoIsCaIrLiIoA wrote:what is supposed to do
int pto(void)
{int a[50]={0};
a[0]=1; a[1]=2; a[2]=3; a[3]=4;
j=0;
a[++j]=a[j]+a[j+1];
return a[j-1];
}
what will be the return value?
undefined, see a similar example:
http://www.eskimo.com/~scs/c-faq.com...valorder1.html
Xicheng
thank U
RSoIsCaIrLiIoA wrote:what is supposed to do
int pto(void)
{int a[50]={0};
a[0]=1; a[1]=2; a[2]=3; a[3]=4;
j=0;
a[++j]=a[j]+a[j+1];
return a[j-1];
}
what will be the return value?
This might be a useful link for you:
http://groups.google.com/group/micro...c4d4d9039ea004
Abdo Haji-Ali
Programmer
In|Framez
这篇关于一个[++ j]的一个= [j]的一个+ [J + 1];的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!