Language: C++

#include <iostream>
using namespace std;

int main(){
        int sx,sy,tx,ty;
        cin >> sx >> sy >> tx >> ty;
        const int dx=tx-sx,dy=ty-sy;

        cout << string(dy,’U’) << string(dx,’R’);

        cout << string(dy,’D’) << string(dx,’L’);

        cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;

        cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;

        cout << endl;
        return 0;

}


Compiler output:
a.cc:9:27: error: extended character ’ is not valid in an identifier
    9 |         cout << string(dy,’U’) << string(dx,’R’);
      |                           ^
a.cc:9:27: error: extended character ’ is not valid in an identifier
a.cc:9:45: error: extended character ’ is not valid in an identifier
    9 |         cout << string(dy,’U’) << string(dx,’R’);
      |                                             ^
a.cc:9:45: error: extended character ’ is not valid in an identifier
a.cc:11:27: error: extended character ’ is not valid in an identifier
   11 |         cout << string(dy,’D’) << string(dx,’L’);
      |                           ^
a.cc:11:27: error: extended character ’ is not valid in an identifier
a.cc:11:45: error: extended character ’ is not valid in an identifier
   11 |         cout << string(dy,’D’) << string(dx,’L’);
      |                                             ^
a.cc:11:45: error: extended character ’ is not valid in an identifier
a.cc:13:17: error: extended character ’ is not valid in an identifier
   13 |         cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;
      |                 ^
a.cc:13:17: error: extended character ’ is not valid in an identifier
a.cc:13:36: error: extended character ’ is not valid in an identifier
   13 |         cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;
      |                                    ^
a.cc:13:36: error: extended character ’ is not valid in an identifier
a.cc:13:56: error: extended character ’ is not valid in an identifier
   13 |         cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;
      |                                                        ^
a.cc:13:56: error: extended character ’ is not valid in an identifier
a.cc:13:64: error: extended character ’ is not valid in an identifier
   13 |         cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;
      |                                                                ^
a.cc:13:64: error: extended character ’ is not valid in an identifier
a.cc:15:17: error: extended character ’ is not valid in an identifier
   15 |         cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;
      |                 ^
a.cc:15:17: error: extended character ’ is not valid in an identifier
a.cc:15:36: error: extended character ’ is not valid in an identifier
   15 |         cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;
      |                                    ^
a.cc:15:36: error: extended character ’ is not valid in an identifier
a.cc:15:56: error: extended character ’ is not valid in an identifier
   15 |         cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;
      |                                                        ^
a.cc:15:56: error: extended character ’ is not valid in an identifier
a.cc:15:64: error: extended character ’ is not valid in an identifier
   15 |         cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;
      |                                                                ^
a.cc:15:64: error: extended character ’ is not valid in an identifier
a.cc: In function 'int main()':
a.cc:9:27: error: '\U00002019U\U00002019' was not declared in this scope
    9 |         cout << string(dy,’U’) << string(dx,’R’);
      |                           ^~~
a.cc:9:45: error: '\U00002019R\U00002019' was not declared in this scope
    9 |         cout << string(dy,’U’) << string(dx,’R’);
      |                                             ^~~
a.cc:11:27: error: '\U00002019D\U00002019' was not declared in this scope
   11 |         cout << string(dy,’D’) << string(dx,’L’);
      |                           ^~~
a.cc:11:45: error: '\U00002019L\U00002019' was not declared in this scope
   11 |         cout << string(dy,’D’) << string(dx,’L’);
      |                                             ^~~