Dodle Posted October 26, 2009 Report Share Posted October 26, 2009 I have always used iostream to print to the command line in my programs because that is what I was taught from the tutorials and books I have read. But when I was talking about it with my brother who is a C++ programmer, he was not familiar with iostream. He told me that he uses stdio.h, I think he referred to it as standard input/output. So I did some looking around and found a "hello world" tutorial using stdio.h and was wondering which would be better for me to practice. Is one more preferred in general? Are there any benefits to one over the other?#include <iostream>using namespace std;int main(){ cout << "Hello World!"; return 0;}#include <stdio.h>int main(){ printf("Hello World!"); return 0;} Quote Link to comment Share on other sites More sharing options...
ɹəuəllıʍ ʇɐb Posted October 27, 2009 Report Share Posted October 27, 2009 I have no idea what iostream is - never heard of it. You could open the two files and compare them - maybe that would give you some insight...I wonder why this topic was closed? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.