Hi everyone,

I want to implent dos like arrow keys for browsing between the previously typed text. What is a good way of doing this, I was thinking of storing them in pointers,
Code:
char *p[16];
and when counter is > 16, free and re-allocate 0, and start there again. This should keep 17 commands in memory.

Are there any good algorithms for this? Or can someone show an example of how this could be done?

Best regards.

  • OS: MS Windows XP
    Compiler: MS VC++ 6.0