What is the main requirement to write a C++ program ?
Importing the iostream library is not required to write a C++ program.
But if you want to for example write output to the console i.e. std::cout,
you will need to first import this library.
🔔 In recent compiler, the
returnstatement can even be avoided, but the signature of themainfunction should still be (at least) :
int main();