Printing arrays to curses screen

This is a discussion on Printing arrays to curses screen within the C++ Programming forums, part of the General Programming Boards category; Hello all. I have a program in which I have a string array and a integer array (an initial list ...

  1. #1
    Registered User
    Join Date
    Apr 2007
    Posts
    16

    Printing arrays to curses screen

    Hello all. I have a program in which I have a string array and a integer array (an initial list and score list) to output at the end of my snakes game. Im wondering how can i output these two arrays to the screen ? Its using the curses library, and any help would be greatly appreciated!

  2. #2
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,333
    If you have arrays, then for loops seem appropriate.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  3. #3
    Registered User
    Join Date
    Apr 2007
    Posts
    16
    Yup im using for loops, i just am not sure what to use to output to the curses screen. Basically i want to cout it to curses screen (but since u cant cout to curses screen thats where im stuck). Ive tried mvaddstr and mvaddch but just cant seem to figure it out. Thanks =)

  4. #4
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,333
    Post code?
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  5. #5
    Registered User
    Join Date
    Apr 2007
    Posts
    16
    Will post it tomorrow when i can get to the computer its on =)

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Printing \n on the screen in C
    By swgh in forum C Programming
    Replies: 4
    Last Post: 05-18-2007, 03:52 PM
  2. Converting from Screen to World Coordinates
    By DavidP in forum Game Programming
    Replies: 9
    Last Post: 05-11-2004, 12:51 PM
  3. Problem With search a file and printing to screen
    By sell682 in forum C++ Programming
    Replies: 4
    Last Post: 05-02-2004, 05:55 AM
  4. question about printing on screen and not overwriting text...
    By revelation437 in forum C Programming
    Replies: 2
    Last Post: 12-14-2002, 01:48 PM
  5. Printing out contents of a file to the screen
    By Simon in forum C Programming
    Replies: 18
    Last Post: 10-21-2002, 08:05 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21