Search:

Type: Posts; User: hamsteroid

Page 1 of 3 1 2 3

Search: Search took 0.01 seconds.

  1. Replies
    4
    Views
    1,028

    Thanks.

    Thanks.
  2. Replies
    4
    Views
    1,028

    Hi MacGyver, agreed, it's all arbitrary but I am...

    Hi MacGyver, agreed, it's all arbitrary but I am just curious that all! :) What was the highest or lowest address value did you ever read on an average system?
  3. Replies
    4
    Views
    1,028

    A feel for memory

    Hi,

    I am having fun with pointers just right now. Right now, I'm playing with them at a very basic level, looking at the way the compiler assigns memory addresses and how to dereference the values...
  4. Thanks Zuk, that was killing me - I did it right...

    Thanks Zuk, that was killing me - I did it right for the while fgets loop further down but didn't spot the difference. Thanks for setting me straight! :)
  5. writing a string to file skips 1st character

    Hi,
    I have been playing with the write to file functions lately which are very useful and mostly straight forward. However I have come across one problem I can't get my head around. The problem is...
  6. Replies
    14
    Views
    5,720

    Thanks zacs. I guess I think of SDL first since...

    Thanks zacs. I guess I think of SDL first since it's pretty well documented to integrate with dev-c++ for example. If it works with plain C - then even better. Up to now I have never used a graphic...
  7. Replies
    14
    Views
    5,720

    Have you guys used SDL with plain C ? Most...

    Have you guys used SDL with plain C ? Most examples I have looked at use C++. I'm using Dev-C++ 4.99 myself and put SDL's lib and include files in their respective locations. I'd be curious to see...
  8. Replies
    14
    Views
    5,720

    Wow! I was looking at a SDL tutorial...

    Wow! I was looking at a SDL tutorial and I might go graphical instead. It looks to be a lot more simpler and ultimately more flexible and portable :)
  9. Replies
    14
    Views
    5,720

    Thanks dwks! I'll read up about ncurses.

    Thanks dwks! I'll read up about ncurses.
  10. Replies
    14
    Views
    5,720

    I played around with array sizes and used the...

    I played around with array sizes and used the rand & srand functions to give different sizes. Great fun thanks! :)

    Is it possible to move a character (l,r,u and down) on the screen simply pressing...
  11. Replies
    14
    Views
    5,720

    Ok thanks Mats - I thought I might be stretching...

    Ok thanks Mats - I thought I might be stretching it there alright. :)
  12. Replies
    14
    Views
    5,720

    Thanks. I tried it tonight and got my little...

    Thanks. I tried it tonight and got my little square grid. For debugging I printed out the memory each character took using lx%.

    eg.
    grid[0][0] = 9fcba864
    grid[1][0] = 9fcba865
    grid[2][0] =...
  13. Replies
    14
    Views
    5,720

    Thanks Salem - I'll give this a whirl tonight.

    Thanks Salem - I'll give this a whirl tonight.
  14. Replies
    14
    Views
    5,720

    Wish to populate a 2D array using pointers

    Hi,

    Last night I had a go at populating a 2D 8x8 array using pointers - I want to use pointers as a memory exercise. From memory this is what I had:



    int main()
    {
    char gameGrid[8][8];
  15. Replies
    32
    Views
    3,714

    Nice code Halios - I promise to look at it once I...

    Nice code Halios - I promise to look at it once I get onto arrays next - just finishing up on ifs, loops now... Looks like nice clean though.. I understand it for the most part. As you say it's hard...
  16. Please recommend a minimal c compiler and libraries required

    Hi,

    I normally use linux for c coding but I am curious to know what is the smallest c compiler you could get for windows and what would be the minimal libraries required to go with it.

    For...
  17. Replies
    10
    Views
    2,778

    Yeah, that's true, I usually delete using...

    Yeah, that's true, I usually delete using highlight mode (usually for cutting) or simply dd and yank it... but it is handy to delete with backspace while still in insert mode. Only noticed the...
  18. Replies
    10
    Views
    2,778

    Just to say that "set nocindent" did the trick!...

    Just to say that "set nocindent" did the trick! :) Actually on mate's pc I came across another weird vim property... when you entered text in insert mode and then... come out of insert mode for...
  19. Replies
    32
    Views
    3,714

    I like that, I'm hitting that problem a lot -...

    I like that, I'm hitting that problem a lot - similar to my woe in tutorial practise of Simple Simon. Would be a good sticky if not in the faq already? :)
  20. Replies
    3
    Views
    1,389

    Thanks Kurt... I'll try fflush(stdout); Btw,...

    Thanks Kurt... I'll try fflush(stdout);

    Btw, was used twice - once to show the user and again to restart the same seed to compare...

    srand((unsigned int)seed); /* initialise the sequence...
  21. Replies
    3
    Views
    1,389

    time or display problem I am not sure!

    Hi I have went through a tutorial teaching me time and rand. The game is simple simon and the user tries to enter the same digits as the computer. This program works, ie If I match the computer's...
  22. Wow! scanf is really the basic tool it says it...

    Wow! scanf is really the basic tool it says it is.. so many issues with it. For basic purposes as like the program above, I'll stick with the scanf(" %c") with the space. Works fine for learning...
  23. Thanks Koni - I'll check that out now. Felt...

    Thanks Koni - I'll check that out now. Felt spooked there for a sec since I have been using scanf in umpteen examples - but the issue now only showed up since I was in a loop which highlighted the...
  24. Think I found my bug... if I change ...

    Think I found my bug... if I change

    scanf("%c", &answer);
    to
    scanf(" %c", &answer);
    It handles the carriage return correctly (ie does not use it for the next input).

    Whereas if I leave...
  25. scanf is also reading the return character when I enter a value and hit return

    Hi,

    I'm going through loops at the moment in C. This example is simply an infinite loop which takes a value from the user and then asks do they want to continue and if so take another value and so...
Results 1 to 25 of 62
Page 1 of 3 1 2 3