0

Can I use printf for hello world by including #include <stdio.h> also?

#include <stdio.h> and use printf for hello world Why we use <iostream> instead of <stdio.h>?

24th Dec 2016, 3:59 AM
Ka Yip
2 Antworten
+ 6
<iostream> is part of the standard C++ library. <stdio.h> is part of the standard C library. While stdio.h will work in C++, it isn't recommended because it does not provide everything that iostream includes as iostream is specifically for C++.
24th Dec 2016, 4:12 AM
Hatsy Rei
Hatsy Rei - avatar
+ 1
NO U CANT , KA YIP stdio.h is only used in C....u have to use IOSTREAM...PLS FOLLOW ME KA YIP
24th Dec 2016, 4:37 AM
MEDHIR
MEDHIR - avatar