Print Formatting

This is a discussion on Print Formatting within the C++ Programming forums, part of the General Programming Boards category; I've read about print formatting and still don't know what i'm doing. All i'm trying to do is print data ...

  1. #1
    Registered User
    Join Date
    Mar 2007
    Posts
    109

    Print Formatting

    I've read about print formatting and still don't know what i'm doing. All i'm trying to do is print data that currently prints in a line straight down and make it print in a table form.

  2. #2
    Registered User
    Join Date
    Oct 2001
    Posts
    2,934
    >and make it print in a table form
    Some of this you've probably already tried, but here are some options. You can use std::setw() to set the width of each column. Also remember that by default, all output is right justified in the field (column). You can use std::left and std::right to change the justification.

  3. #3
    Registered User
    Join Date
    Oct 2001
    Posts
    2,934
    And if you're not happy with that, there's always printf().

  4. #4
    Registered User
    Join Date
    Mar 2007
    Posts
    109
    i got it thanks for all the help i appreciate it.
    Last edited by DarkDot; 05-07-2007 at 06:31 PM.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. merging linked lists
    By scwizzo in forum C++ Programming
    Replies: 15
    Last Post: 09-14-2008, 06:07 PM
  2. Personal Program that is making me go wtf?
    By Submeg in forum C Programming
    Replies: 20
    Last Post: 06-27-2006, 01:13 AM
  3. Scope And Parameter Passing
    By djwicks in forum C Programming
    Replies: 6
    Last Post: 03-28-2005, 08:26 PM
  4. dos game help
    By kwm32 in forum Game Programming
    Replies: 7
    Last Post: 03-28-2004, 06:28 PM
  5. What kind of programs should I start writing?
    By Macabre in forum C++ Programming
    Replies: 23
    Last Post: 04-12-2003, 09:13 PM

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