locked
Ans of sunil_singhal_10e2aa Question ... RRS feed

  • Question

  •  

    #include <stdio.h>
    int main(void)

    {
                   char input[100];
                   scanf("%100s", input);
                   printf("1 to %s\n", input);
                   return 0;
    }



     

     

    Friday, May 25, 2007 3:10 PM

All replies

  • what are you trying to do man?
    explain your logic.
    Friday, May 25, 2007 4:15 PM
  • it will take the first 100 charectors as input and the rest will be ignored but can you explain how cum it is running fine while you have not used an "&" sign while using scanf
    Friday, May 25, 2007 7:30 PM
  • i think neither you nor that guy have understood my problem.
    my problem is to print numbers from 1 to N(the value of  N being taken from user) without using any looping technique, recursion or indirect recursion or goto in "C language".
    i hope question is clear now
    Saturday, May 26, 2007 1:23 AM
  •  
    Preetam_Ghosh_d910d0

     

    Its a string MAN not character .

    Saturday, May 26, 2007 2:22 PM
  • U want that print 1 to n without using loop

     

    So i m printing 1 to N ......thats it.

    Saturday, May 26, 2007 2:24 PM
  • but this is surely not an answer to my question.
    you got me wrong
    Sunday, May 27, 2007 6:10 AM