Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

difference betweeen and ?

i have seen many codes which have both these header files included. so i wanted to know if there's a difference in their functioning, coz someone told me that they do more or less the same thing.

thank you in advance.

Comments

  • Geeth AsokanGeeth Asokan Member Posts: 127
    : i have seen many codes which have both these header files included. so i wanted to know if there's a difference in their functioning, coz someone told me that they do more or less the same thing.
    :
    : thank you in advance.
    :

    Hi,

    Both header files do more or less the same thing but the header file, [b]#include [/b] or:

    [code]
    #include
    using namespace std;
    [/code]

    includes the C++ functions [b]cin >>[/b], [b]cout <<[/b] etc.

    Hope this helps,
  • DariusDarius Member Posts: 1,666
    : : i have seen many codes which have both these header files included. so i wanted to know if there's a difference in their functioning, coz someone told me that they do more or less the same thing.
    : :
    : : thank you in advance.
    : :
    :
    : Hi,
    :
    : Both header files do more or less the same thing but the header file, [b]#include [/b] or:
    :
    : [code]
    : #include
    : using namespace std;
    : [/code]
    :
    : includes the C++ functions [b]cin >>[/b], [b]cout includes the C++ OBJECTS cin and cout, which overload the << and >> operators to handle IO.

    :
    : Hope this helps,
    :

    A mechanical push mower and a gas-powered sit-down mower, both mow yards, that doesn't mean one isn't preferable to the other. Unless you have some pressing reason otherwise you should ALWAYS use iostreams.

    "We can't do nothing and think someone else will make it right."
    -Kyoto Now, Bad Religion

  • blaqvenomblaqvenom Member Posts: 2


    : : Hi,
    : :
    : : Both header files do more or less the same thing but the header file, [b]#include [/b] or:
    : :
    : : [code]
    : : #include
    : : using namespace std;
    : : [/code]
    : :
    : : includes the C++ functions [b]cin >>[/b], [b]cout <<[/b] etc.
    :
    : <iostream> includes the C++ OBJECTS cin and cout, which overload the << and >> operators to handle IO.
    :
    : :
    : : Hope this helps,
    : :
    :
    : A mechanical push mower and a gas-powered sit-down mower, both mow yards, that doesn't mean one isn't preferable to the other. Unless you have some pressing reason otherwise you should ALWAYS use iostreams.
    :
    : "We can't do nothing and think someone else will make it right."
    : -Kyoto Now, Bad Religion
    :
    hey thanx guys that has certainly laid all my doubts to rest

  • Andre YoungAndre Young USAMember Posts: 0

    ________ [ http://forcoder.org ] free video tutorials and ebooks about ( MATLAB, Scratch, Go, C, Delphi, C#, Visual Basic .NET, Ruby, Swift, Perl, JavaScript, PHP, C++, Assembly, R, Python, Objective-C, Visual Basic, Java, PL/SQL Transact-SQL, Kotlin, Scheme, Hack, Awk, VBScript, LabVIEW, Julia, F#, Bash, Erlang, Fortran, Apex, ML, Prolog, FoxPro, Lua, Crystal, Ada, Dart, SAS, Lisp, COBOL, Clojure, D, Scala, Alice, ABAP, Logo, Rust ) ____

Sign In or Register to comment.