I have just started with a tutorial in c++ and i wonder if anyone can tell me what´s wrong with this code

#include <iostream>

using namespace std; //so the program can see cout and end1

int main()
{
        
          for  (int x = 0; x < 10; x++) {
              
               cout<< x <<end1;
               }
              cin.get();
}

> and i wonder if anyone can tell me what´s wrong with this code
Posting error messages helps.

> end1;
In your case, I guess you mean endl
That's lower-case "L" (l) at the end, not numeric one(1).

that solved the problem, thaks

Use return 0; at the end of the program, otherwise compiler will throw warning.
Its a good programming practice.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.