Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
Re:请教一个C语言入门问题In Reply To:请教一个C语言入门问题 Posted by:DreamOfGame at 2009-08-15 21:45:33 > n[0]=0; > for(i=1;i<=nn;i++) > { > scanf("%s",s+n[i-1]); > n[i]=strlen(s+n[i-1]); > n[i]+=n[i-1]; > s[n[i]++]='a'-i; > } > > n[0]=0; > for(i=1;i<=nn;i++) > { > scanf("%s",s+n[i-1]); > n[i]=strlen(s); > s[n[i]++]='a'-1; > } > > 这两种写法有什么区别?? 找了一下午错,竟然是这个问题,晕死了。。。 Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator