Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

请教一个C语言入门问题

Posted by DreamOfGame at 2009-08-15 21:45:33 on Problem 3294
    nn[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;
    }
    
    nn[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:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator