Language: C++

#include<iostream>
using namespace


int main(){

int x  , y;
char op;

while(1){
cin >> x >>  op  >> y;
if( op == "?" ) break;

if ( op == "+" ){ cout << x + y << endl;
}
if ( op == "-" ){ cout << x - y << endl;
}
if ( op == "*" ){ cout << x * y << endl;
}
if ( op == "/" ){ cout << x / y << endl:
}
}

return 0 ;

}

Compiler output:
a.cc:5:1: error: expected identifier before 'int'
    5 | int main(){
      | ^~~
a.cc:2:16: error: expected ';' before 'int'
    2 | using namespace
      |                ^
      |                ;
......
    5 | int main(){
      | ~~~             
a.cc: In function 'int main()':
a.cc:11:1: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
   11 | cin >> x >>  op  >> y;
      | ^~~
      | std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:12:8: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   12 | if( op == "?" ) break;
      |     ~~~^~~~~~
a.cc:14:9: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   14 | if ( op == "+" ){ cout << x + y << endl;
      |      ~~~^~~~~~
a.cc:14:19: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   14 | if ( op == "+" ){ cout << x + y << endl;
      |                   ^~~~
      |                   std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:14:36: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   14 | if ( op == "+" ){ cout << x + y << endl;
      |                                    ^~~~
      |                                    std::endl
In file included from /usr/include/c++/14/iostream:41:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
a.cc:16:9: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   16 | if ( op == "-" ){ cout << x - y << endl;
      |      ~~~^~~~~~
a.cc:16:19: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   16 | if ( op == "-" ){ cout << x - y << endl;
      |                   ^~~~
      |                   std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:16:36: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   16 | if ( op == "-" ){ cout << x - y << endl;
      |                                    ^~~~
      |                                    std::endl
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
a.cc:18:9: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   18 | if ( op == "*" ){ cout << x * y << endl;
      |      ~~~^~~~~~
a.cc:18:19: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   18 | if ( op == "*" ){ cout << x * y << endl;
      |                   ^~~~
      |                   std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:18:36: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   18 | if ( op == "*" ){ cout << x * y << endl;
      |                                    ^~~~
      |                                    std::endl
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
a.cc:20:9: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   20 | if ( op == "/" ){ cout << x / y << endl:
      |      ~~~^~~~~~
a.cc:20:19: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   20 | if ( op == "/" ){ cout << x / y << endl:
      |                   ^~~~
      |                   std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:20:36: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   20 | if ( op == "/" ){ cout << x / y << endl:
      |                                    ^~~~
      |                                    std::endl
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~