Language: C++

#include <bits/stdc++.h>
#define rep(i,n) for(int i=0;i<n;i++)
#define FOR(i,start,end) for(int i=start;i<=end;i++)
const int INF = 1001001001;
typedef long long ll;
const ll MOD=1000000007;
using namespace std;
template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return 1; } return 0; }
template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return 1; } return 0; }
template<class T>auto MAX(const T& a) { return *max_element(a.begin(),a.end()); }
template<class T>auto MIN(const T& a) { return *min_element(a.begin(),a.end()); }
template<class T, class U>U SUM(const T& a, const U& v) { return accumulate(a.begin(),a.end(), v); }
template<class T, class U>U COUNT(const T& a, const U& v) { return count(a.begin(),a.end(), v); }
template<class T, class U>int LOWER(const T& a, const U& v) { return lower_bound(a.begin(),a.end(), v) - a.begin(); }
template<class T, class U>int UPPER(const T& a, const U& v) { return upper_bound(a.begin(),a.end(), v) - a.begin(); }
int GCD(int a, int b) { return b ? GCD(b, a%b) : a; }
int LCM(int a, int b) { int g = GCD(a, b); return a / g * b; }

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;
 }

Compiler output:
a.cc:26:19: error: extended character ’ is not valid in an identifier
   26 | cout << string(dy,’U’) << string(dx,’R’);
      |                   ^
a.cc:26:19: error: extended character ’ is not valid in an identifier
a.cc:26:37: error: extended character ’ is not valid in an identifier
   26 | cout << string(dy,’U’) << string(dx,’R’);
      |                                     ^
a.cc:26:37: error: extended character ’ is not valid in an identifier
a.cc:29:19: error: extended character ’ is not valid in an identifier
   29 | cout << string(dy,’D’) << string(dx,’L’);
      |                   ^
a.cc:29:19: error: extended character ’ is not valid in an identifier
a.cc:29:37: error: extended character ’ is not valid in an identifier
   29 | cout << string(dy,’D’) << string(dx,’L’);
      |                                     ^
a.cc:29:37: error: extended character ’ is not valid in an identifier
a.cc:32:10: error: extended character ’ is not valid in an identifier
   32 |  cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;
      |          ^
a.cc:32:10: error: extended character ’ is not valid in an identifier
a.cc:32:29: error: extended character ’ is not valid in an identifier
   32 |  cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;
      |                             ^
a.cc:32:29: error: extended character ’ is not valid in an identifier
a.cc:32:49: error: extended character ’ is not valid in an identifier
   32 |  cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;
      |                                                 ^
a.cc:32:49: error: extended character ’ is not valid in an identifier
a.cc:32:57: error: extended character ’ is not valid in an identifier
   32 |  cout << ’L’ << string(dy+1,’U’) << string(dx+1,’R’) << ’D’;
      |                                                         ^
a.cc:32:57: error: extended character ’ is not valid in an identifier
a.cc:35:10: error: extended character ’ is not valid in an identifier
   35 |  cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;
      |          ^
a.cc:35:10: error: extended character ’ is not valid in an identifier
a.cc:35:29: error: extended character ’ is not valid in an identifier
   35 |  cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;
      |                             ^
a.cc:35:29: error: extended character ’ is not valid in an identifier
a.cc:35:49: error: extended character ’ is not valid in an identifier
   35 |  cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;
      |                                                 ^
a.cc:35:49: error: extended character ’ is not valid in an identifier
a.cc:35:57: error: extended character ’ is not valid in an identifier
   35 |  cout << ’R’ << string(dy+1,’D’) << string(dx+1,’L’) << ’U’;
      |                                                         ^
a.cc:35:57: error: extended character ’ is not valid in an identifier
a.cc: In function 'int main()':
a.cc:26:19: error: '\U00002019U\U00002019' was not declared in this scope
   26 | cout << string(dy,’U’) << string(dx,’R’);
      |                   ^~~
a.cc:26:37: error: '\U00002019R\U00002019' was not declared in this scope
   26 | cout << string(dy,’U’) << string(dx,’R’);
      |                                     ^~~
a.cc:29:19: error: '\U00002019D\U00002019' was not declared in this scope
   29 | cout << string(dy,’D’) << string(dx,’L’);
      |                   ^~~
a.cc:29:37: error: '\U00002019L\U00002019' was not declared in this scope
   29 | cout << string(dy,’D’) << string(dx,’L’);
      |                                     ^~~