setw() and <iomanip> Header

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • saiavinashiitr
    New Member
    • Mar 2014
    • 16

    setw() and <iomanip> Header

    what does setw() function do??can u give an example...
    when are <iomanip> and <sstream> header used???
  • weaknessforcats
    Recognized Expert Expert
    • Mar 2007
    • 9214

    #2
    setw is a manipulator. I can't answer this question unless you know about a) references, b) operator overloading, c) the std::basic_ostr eam class.

    The sstream header is used with string streams. A string stream is an object that behaves like a stream.

    Comment

    • saiavinashiitr
      New Member
      • Mar 2014
      • 16

      #3
      i want to know how does setw() works...pls tell with an example.

      Comment

      Working...