Search:

Type: Posts; User: Giri

Search: Search took 0.01 seconds.

  1. Replies
    10
    Views
    2,267

    Hi All, Thanks so much for the responses! I...

    Hi All,

    Thanks so much for the responses! I have been playing around with the below code and have a question regarding it.



    #include <stdio.h>
    #include <stdlib.h>
    #include <ctype.h>
  2. Replies
    10
    Views
    2,267

    How to check whether input is positive...

    Hi Guys,

    I am trying to read in TWO unsigned long long variables, however, I would like to know whether the user actually entered two positive numbers within the range of an
    unsigned long long...
  3. Hi Grumpy, I assumed that when it read the...

    Hi Grumpy,

    I assumed that when it read the last digit on the 2nd line, it would return EOF.

    Is there a way I can ensure EOF is returned after the 2nd line has been read?

    Thanks.

    Giri
  4. Not Entering For Loop / Placing Input into Console (Eclipse)

    Hi Guys,

    This is in relation to some code I posted earlier. I am finding that the ForLoop located at the bottom of my code is not being entered. Any ideas why?

    The input for this program is in...
  5. Replies
    6
    Views
    1,202

    Ok. This is what I have written so far. ...

    Ok.

    This is what I have written so far.



    #define MAX_X_DIM 31
    #define MAX_Y_DIM 41
    int array[MAX_Y_DIM][MAX_X_DIM];
  6. Replies
    6
    Views
    1,202

    Hi Quzah, I wouldn't have thought so, because...

    Hi Quzah,

    I wouldn't have thought so, because the loop freezes after reading the first line of input. It doesn't seem to get to the 2nd line of input.

    Kind Regards,

    Giri
  7. Replies
    6
    Views
    1,202

    Hi Oogabooga, Thanks for that. I realized my...

    Hi Oogabooga,

    Thanks for that. I realized my mistake - I should have been putting '10' instead of '-38'. I initially put -38 because I noticed that -38 was being printed when a NewLine was...
  8. Replies
    6
    Views
    1,202

    Problem with If, &&, ||

    Hi Guys,

    I currently have the below code:



    while( (c = getchar()) != EOF)
    if ( c != -38 && (c < '0' || c > '3') )
    return false;
  9. Thread: "If" Test

    by Giri
    Replies
    5
    Views
    947

    Thanks so much nonoob & stahta01!! The program...

    Thanks so much nonoob & stahta01!!

    The program is now running as it should ;)

    All the best,

    Giri
  10. Thread: "If" Test

    by Giri
    Replies
    5
    Views
    947

    "If" Test

    Hi All,

    I have the below code within a For Loop. I want the code to go back to the start of the loop if ANY of the below variables are not equal to a common value.

    I was just curious as to...
Results 1 to 10 of 10