- 5
Same code but shorter
#include <iostream> using namespace std; int main() {cout << "Hello world!" << endl << "I love programming!";}
5 Réponses
+ 2
4 answers and no one helped you... the shortest possible code for this is:
#include <iostream>
using namespace std;
int main() { cout << "Hello World\nI love programming!"; }
0
you changed the syntax, this code won't make any difference of compile time nor run time.
- 1
but this code is easier to write ))
- 1
this is a relative question.
it's more comfortable to me to write it like this:
#include <iostream>
int main()
{
std::cout << "hello world" << std::endl;
}
- 1
Ahem.
int main()
{
std::cout << "Hello World\n";
}