Language: C++

int main(void){
 int sx,sy,tx,ty;
 cin >> sx >> sy >> tx >> ty;

 const int dx=tx-sx,dy=ty-sy;

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

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

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

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

 // EndLine
 cout << endl;
 return 0;
}

Compiler output:
a.cc:8:20: error: extended character ’ is not valid in an identifier
    8 |  cout << string(dy,’U’) << string(dx,’R’);
      |                    ^
a.cc:8:20: error: extended character ’ is not valid in an identifier
a.cc:8:38: error: extended character ’ is not valid in an identifier
    8 |  cout << string(dy,’U’) << string(dx,’R’);
      |                                      ^
a.cc:8:38: error: extended character ’ is not valid in an identifier
a.cc:11:20: error: extended character ’ is not valid in an identifier
   11 |  cout << string(dy,’D’) << string(dx,’L’);
      |                    ^
a.cc:11:20: error: extended character ’ is not valid in an identifier
a.cc:11:38: error: extended character ’ is not valid in an identifier
   11 |  cout << string(dy,’D’) << string(dx,’L’);
      |                                      ^
a.cc:11:38: error: extended character ’ is not valid in an identifier
a.cc:14:10: error: extended character ’ is not valid in an identifier
   14 |  cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;
      |          ^
a.cc:14:10: error: extended character ’ is not valid in an identifier
a.cc:14:29: error: extended character ’ is not valid in an identifier
   14 |  cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;
      |                             ^
a.cc:14:29: error: extended character ’ is not valid in an identifier
a.cc:14:49: error: extended character ’ is not valid in an identifier
   14 |  cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;
      |                                                 ^
a.cc:14:49: error: extended character ’ is not valid in an identifier
a.cc:14:57: error: extended character ’ is not valid in an identifier
   14 |  cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;
      |                                                         ^
a.cc:14:57: error: extended character ’ is not valid in an identifier
a.cc:17:10: error: extended character ’ is not valid in an identifier
   17 |  cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;
      |          ^
a.cc:17:10: error: extended character ’ is not valid in an identifier
a.cc:17:29: error: extended character ’ is not valid in an identifier
   17 |  cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;
      |                             ^
a.cc:17:29: error: extended character ’ is not valid in an identifier
a.cc:17:49: error: extended character ’ is not valid in an identifier
   17 |  cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;
      |                                                 ^
a.cc:17:49: error: extended character ’ is not valid in an identifier
a.cc:17:57: error: extended character ’ is not valid in an identifier
   17 |  cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;
      |                                                         ^
a.cc:17:57: error: extended character ’ is not valid in an identifier
a.cc: In function 'int main()':
a.cc:3:2: error: 'cin' was not declared in this scope
    3 |  cin >> sx >> sy >> tx >> ty;
      |  ^~~
a.cc:8:2: error: 'cout' was not declared in this scope
    8 |  cout << string(dy,’U’) << string(dx,’R’);
      |  ^~~~
a.cc:8:20: error: '\U00002019U\U00002019' was not declared in this scope
    8 |  cout << string(dy,’U’) << string(dx,’R’);
      |                    ^~~
a.cc:8:10: error: 'string' was not declared in this scope
    8 |  cout << string(dy,’U’) << string(dx,’R’);
      |          ^~~~~~
a.cc:8:38: error: '\U00002019R\U00002019' was not declared in this scope
    8 |  cout << string(dy,’U’) << string(dx,’R’);
      |                                      ^~~
a.cc:11:20: error: '\U00002019D\U00002019' was not declared in this scope
   11 |  cout << string(dy,’D’) << string(dx,’L’);
      |                    ^~~
a.cc:11:38: error: '\U00002019L\U00002019' was not declared in this scope
   11 |  cout << string(dy,’D’) << string(dx,’L’);
      |                                      ^~~
a.cc:20:10: error: 'endl' was not declared in this scope
   20 |  cout << endl;
      |          ^~~~