How to insert "tab" into a stream of output??

This is a discussion on How to insert "tab" into a stream of output?? within the C++ Programming forums, part of the General Programming Boards category; Does anyone know how to insert "tab" into a stream of output so they can align with each other? Code: ...

  1. #1
    JCK
    JCK is offline
    Registered User
    Join Date
    Oct 2002
    Posts
    25

    How to insert "tab" into a stream of output??

    Does anyone know how to insert "tab" into a stream of output so they can align with each other?

    Code:
     outFile << first_name << last_name << type_coverage << zip_code
        << premium << endl;                   //output premium to file output
    Thanks so much

  2. #2
    Code Goddess Prelude's Avatar
    Join Date
    Sep 2001
    Posts
    9,796
    >Does anyone know how to insert "tab" into a stream of output so they can align with each other?
    The '\t' escape character.

    -Prelude
    My best code is written with the delete key.

  3. #3
    JCK
    JCK is offline
    Registered User
    Join Date
    Oct 2002
    Posts
    25
    Thanks so much prelude!! I really appreciate your help!!

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. strange virtual function output
    By George2 in forum C++ Programming
    Replies: 4
    Last Post: 02-08-2008, 07:08 AM
  2. Basic C input output program help
    By trevordunstan in forum C Programming
    Replies: 2
    Last Post: 01-27-2008, 05:41 PM
  3. 2d game
    By JordanCason in forum Game Programming
    Replies: 5
    Last Post: 12-08-2007, 09:08 PM
  4. Passing file stream as function parameter
    By simonc2 in forum C++ Programming
    Replies: 6
    Last Post: 12-22-2004, 11:12 AM
  5. sorting output on student info program
    By indigo0086 in forum C++ Programming
    Replies: 2
    Last Post: 11-05-2002, 10:29 AM

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