Thursday, July 9, 2009

C ++ question?

Can anybody help me out with the defenition of each one?


#include %26lt;string%26gt;


#include %26lt;cstdlib%26gt;


#include %26lt;iostream%26gt;


#include %26lt;fstream%26gt;


#include %26lt;iomanip%26gt;

C ++ question?
The first library is self explanitory, it allows you to have string types. The cstdlib has all sorts of functions that are general in nature, and almost all apps use them. The final 3 allow you to open and read/write files.
Reply:#include %26lt;string%26gt; - This allows you the ability to use the string data type. It has a lot of baggage which allows you to utilize a lot of different string functions








#include %26lt;cstdlib%26gt;This header defines several general purpose functions, including dynamic memory management, random number generation, communication with the environment, integer arthmetics, searching, sorting and converting, etc.





#include %26lt;iostream%26gt; - This basically allows you to do simple input and output from the keyboard and monitor. Nothing real fancy, it stands for input/output streaming.








#include %26lt;fstream%26gt; - This is exactly the same as iostream but instead of being from the keyboard to the monitor it allows you to read/write to a file.








#include %26lt;iomanip%26gt; - This bad boy allows you to manipulate your input and output so that you can format it and make it look all nice and neat. Most people use this when generating reports to show a certain fixed number of decimal places, spacing, etc.





I hope this helps... If you need any further assistance google it...you'll be suprised at the response you'll get!!!!
Reply:do a web search on each one to get the specifics. There's a man page for each of them.


No comments:

Post a Comment