Search:

Type: Posts; User: flyAway

Search: Search took 0.00 seconds.

  1. Thread: loop

    by flyAway
    Replies
    20
    Views
    2,738

    int isUnique(int values[],int size,int number) {...

    int isUnique(int values[],int size,int number)
    {
    int result=TRUE;
    int i;
    for(i=0; i<size;i++){
    if (number==values[i])
    /*Here causes the...
  2. Replies
    7
    Views
    1,008

    got it,thanks a lot.

    got it,thanks a lot.
  3. Replies
    7
    Views
    1,008

    Hi,Salem what does your profile mean? are you...

    Hi,Salem
    what does your profile mean?
    are you suggesting to use int main rather than void main?
  4. Replies
    7
    Views
    1,008

    Thanks for you two guys' advice. aha,i use VC++...

    Thanks for you two guys' advice.
    aha,i use VC++ 6.0 to edit and compile the source code,so i choose "cout" to print something instead of "printf" just for convenience.

    after your advice,i have...
  5. Replies
    7
    Views
    1,008

    Anyone can help me?

    The code's function is decribed as follow,but it doesn't work.The problem must be caused by the line "strcpy(pStr,temp);//This line caused the problem,so why?"
    --but i don't know why.Any suggestion...
  6. so if your program run ok,the last char it print...

    so if your program run ok,the last char it print will be something uncertain
  7. another problem, ptr1 = (char *)...

    another problem,
    ptr1 = (char *) malloc(i1+i2+1 * sizeof(char));
    //here,u should allocate (i1 + i2) byte memry for these two strings,because there is no "\0" added to the end of a char...
  8. Replies
    2
    Views
    879

    who can help me?

    As we all know that in many C/C++ compilers the size of a null stucture is 1.
    So,what is the usage of a null structure?
    --thanks
Results 1 to 8 of 8