criyle/codenet-compile-errors huggingface dataset:
Language: C++


#include <iostream>
#include <string>
using namespace std;

int main()
{
  string S;
  cin >> S;
  const char tap[] = {'L', 'R'}
  int i = 0;
  for (; i < s.length(); ++i)
    if (tap[i%2] == S[i])
      break;
  cout << (s.length == i ? "Yes" : "No");
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:11:3: error: expected ',' or ';' before 'int'
   11 |   int i = 0;
      |   ^~~
a.cc:12:10: error: 'i' was not declared in this scope
   12 |   for (; i < s.length(); ++i)
      |          ^
a.cc:12:14: error: 's' was not declared in this scope
   12 |   for (; i < s.length(); ++i)
      |              ^
a.cc:15:12: error: 's' was not declared in this scope
   15 |   cout << (s.length == i ? "Yes" : "No");
      |            ^
a.cc:15:24: error: 'i' was not declared in this scope
   15 |   cout << (s.length == i ? "Yes" : "No");
      |                        ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  string S;
  cin >> S;
  for(int i=0 ; i<S.size() ; i+=2){
    if(S.at(i)!='R'||'U'||'D'){
      cout  << "No" << endl;
      return 0;
    }
  }
  for (int i=1 ; i<S.size() ; i+=2){
    if (S.at(i)!='L''U''D'){
      cout << "No" << endl;
      return 0;
    }
  }
 cout << "Yes" << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:21: error: expected ')' before 'U'
   14 |     if (S.at(i)!='L''U''D'){
      |        ~            ^~~
      |                     )
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){
    int n;
    string s;
    cin >> s;
    n = s.size();

    vector<int> a(n);

    for(int i =0; i <n; i++){
        if(s[i]=='U'||s[i] =='D'){
            a.at(i) =0;
        } else if(s[i] =='R'){
            a.at(i) =1;
        } else{
            a.at(i) =-1;
        }


    }
    bool odd;
    bool even = true;
    for(int i = 0; i < n/2; i=i+2){
    if(a.at(i) == -1)
    odd = false;
    }

    if(n>1){
        for(int i =1;i<n/2;i = i+2){
            if(a.at(i) == 1)
            even =false;
        }
    }

    if(odd&&evem){
        cout <<"YES" <<endl;
    }else{
        cout << "NO" << endl;
    }

}

Compiler output:
a.cc: In function 'int main()':
a.cc:37:13: error: 'evem' was not declared in this scope; did you mean 'even'?
   37 |     if(odd&&evem){
      |             ^~~~
      |             even
Language: C

#include <stdio.h>
int main(void){
  char c[101] = {};
  for (i = 0;i < 101;i++)
  {
    scanf("%s",&c[i]);
  }
  for (i = 0;i < 101;i++)
  {
    if (i%2 == 1)
    {
      if (a[i] == 'L')
      {
        printf("No");
        return 0;
      }
    }else{
      if (a[i] == 'R');
      printf("No");
      return 0;
    }
printf("Yes");
    return 0;

Compiler output:
main.c: In function 'main':
main.c:4:8: error: 'i' undeclared (first use in this function)
    4 |   for (i = 0;i < 101;i++)
      |        ^
main.c:4:8: note: each undeclared identifier is reported only once for each function it appears in
main.c:12:11: error: 'a' undeclared (first use in this function)
   12 |       if (a[i] == 'L')
      |           ^
main.c:23:5: error: expected declaration or statement at end of input
   23 |     return 0;
      |     ^~~~~~
main.c:23:5: error: expected declaration or statement at end of input
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  string text;
  cin >> text;
  for(int i=0;i<text.size();i++){
    if(i%2==0){
    if(vec.at(i)=='L'){
    cout << "No" <<endl;
    return 0;}}
    if(i%2==1){
    if(vec.at(i)=='R'){
    cout << "No" <<endl;
    return 0;}}
  }
cout << "Yes" <<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:8: error: 'vec' was not declared in this scope
    8 |     if(vec.at(i)=='L'){
      |        ^~~
a.cc:12:8: error: 'vec' was not declared in this scope
   12 |     if(vec.at(i)=='R'){
      |        ^~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i=0; i<n ; ++i)
#define REP(i,a,b) for(int i=a; i<b; ++i)
typedef long long ll;
//プロトタイプ宣言
int gcd(int , int);


int main(){
  string s;
  cin >> s;
  bool flag = true;
  rep(i,s.size()){
    if(i%2 ==0){
      if(s[i] != 'L' || s[i] != 'U' || s[i] != 'D') bool = false; 
    }
    else {
      if(s[i] != 'R' || s[i] != 'U' || s[i] != 'D') bool = false;
    }
  }
  if(flag) cout << "Yes" << endl;
  else cout << "No" << endl;
}








































//以下、ライブラリ
//ユークリッドの互除法

int gcd(int a, int b) {
  return b ? gcd(b, a%b) : a;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:16:58: error: expected unqualified-id before '=' token
   16 |       if(s[i] != 'L' || s[i] != 'U' || s[i] != 'D') bool = false;
      |                                                          ^
a.cc:19:58: error: expected unqualified-id before '=' token
   19 |       if(s[i] != 'R' || s[i] != 'U' || s[i] != 'D') bool = false;
      |                                                          ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i=0; i<n ; ++i)
#define REP(i,a,b) for(int i=a; i<b; ++i)
typedef long long ll;
//プロトタイプ宣言
int gcd(int , int);


int main(){
  string s;
  cin >> s;
  bool flag = true;
  rep(i,n){
    if(i%2 ==0){
      if(s[i] != 'L' || s[i] != 'U' || s[i] != 'D') bool = false; 
    }
    else {
      if(s[i] != 'R' || s[i] != 'U' || s[i] != 'D') bool = false;
    }
  }
  if(flag) cout << "Yes" << endl;
  else cout << "No" << endl;
}








































//以下、ライブラリ
//ユークリッドの互除法

int gcd(int a, int b) {
  return b ? gcd(b, a%b) : a;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:14:9: error: 'n' was not declared in this scope
   14 |   rep(i,n){
      |         ^
a.cc:3:33: note: in definition of macro 'rep'
    3 | #define rep(i,n) for(int i=0; i<n ; ++i)
      |                                 ^
a.cc:16:58: error: expected unqualified-id before '=' token
   16 |       if(s[i] != 'L' || s[i] != 'U' || s[i] != 'D') bool = false;
      |                                                          ^
a.cc:19:58: error: expected unqualified-id before '=' token
   19 |       if(s[i] != 'R' || s[i] != 'U' || s[i] != 'D') bool = false;
      |                                                          ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
  string S;
  cin>>S;
  
  int n=S.size();
  bool O=true;
  bool E=true;
  for(int i=0;i<n;i+=2){
	if(S.at(i)=="L"){
	O=false;
      break;
    }
  }
  for(int i=1;i<n;i+=2){
	if(S.at(i)=="R"){
	E=false;
      break;
    }
  }
  if(O==true&&E==true) cout<<"Yes"<<endl;
  else  cout<<"No"<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:19: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   11 |         if(S.at(i)=="L"){
      |            ~~~~~~~^~~~~
a.cc:17:19: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   17 |         if(S.at(i)=="R"){
      |            ~~~~~~~^~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
  string S;
  cin>>S;
  int n=S.size();
  bool O=true;
  bool E=true;
  for(int i=0;i<n;i+=2){
	if(S.at(i)==L){
	O=false;
      break;
    }
  }
  for(int i=1;i<n;i+=2){
	if(S.at(i)==R){
	E=false;
      break;
    }
  }
  if(O==true&&E==true) cout<<"Yes"<<endl;
  else  cout<<"No"<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:21: error: 'L' was not declared in this scope
   10 |         if(S.at(i)==L){
      |                     ^
a.cc:16:21: error: 'R' was not declared in this scope
   16 |         if(S.at(i)==R){
      |                     ^
Language: C++

#include <iostream>
#include <string>
#include <stdio.h>
using namespace std;

int main()
{
	char  s[100];
	cin >> s;
	int len = strlen(s);

	for (int i=0; i<len; i = i+2)
	{
		if (s[i] == 'R' || s[i] == 'U' || s[i] == 'D') continue;
		else {
			cout<<"No"<<endl;
			return 0;
		}

	}

	for (int i = 1; i<len; i = i+ 2)
	{
		if (s[i] == 'L' || s[i]=='U' || s[i]=='D') continue;
		else {
			cout<<"No" <<endl;
			return 0;
		}
	}

	cout<<"Yes" <<endl; return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:10:19: error: 'strlen' was not declared in this scope
   10 |         int len = strlen(s);
      |                   ^~~~~~
a.cc:2:1: note: 'strlen' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    1 | #include <iostream>
  +++ |+#include <cstring>
    2 | #include <string>
Language: C++

#include <iostream>
using namespace std;

int main()
{
	char  s[100];
	cin >> s;
	int len = strlen(s);

	for (int i=0; i<len; i = i+2)
	{
		if (s[i] == 'R' || s[i] == 'U' || s[i] == 'D') continue;
		else {
			cout<<"No"<<endl;
			return 0;
		}

	}

	for (int i = 1; i<len; i = i+ 2)
	{
		if (s[i] == 'L' || s[i]=='U' || s[i]=='D') continue;
		else {
			cout<<"No" <<endl;
			return 0;
		}
	}

	cout<<"Yes" <<endl; return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:8:19: error: 'strlen' was not declared in this scope
    8 |         int len = strlen(s);
      |                   ^~~~~~
a.cc:2:1: note: 'strlen' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    1 | #include <iostream>
  +++ |+#include <cstring>
    2 | using namespace std;
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
    char s[100];
    int o=0;
    gets(s);
    for (int i=0;i<strlen(s);i+=2)
    {
        if (s[i]=='L') o=1;
    }
    for (int i=1;i<strlen(s);i+=2)
    {
        if (s[i]=='R') o=1;
    }
    for (int i=0;i<strlen(s);i++)
    {
        if (s[i]!='R'&&s[i]!='U'&&s[i]!='D'&&s[i]!='L') o=1;
    }
    if (o==1)
        printf("NO");
    else
        printf("YES");
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
    7 |     gets(s);
      |     ^~~~
      |     getw
Language: C++

#include <stdio.h>
#include <iostream>
#include <string>
using namespace std;
int main(void){
  string S;
  cin >> S;
  int i;
  bool flug = true;
  for(i=0;i<(int)S.length();i++){
   if((i%2 == 1) && (S[i] == "L")){
     flug = false;
   }else if((i%2 == 0) && (S[i] == "R")){
    flug = false; 
   }else{
     
   }
  }
  
  if(flug == true){
   cout << "Yes" << endl; 
  }else{
   cout << "No" << endl;
  }
  
return 0;
} 

Compiler output:
a.cc: In function 'int main()':
a.cc:11:27: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   11 |    if((i%2 == 1) && (S[i] == "L")){
a.cc:13:33: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   13 |    }else if((i%2 == 0) && (S[i] == "R")){
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){
  string S;
  cin >> S;
  for(int ii=0; ii<S.size(); ii++){
    if(ii%2==0){
      if(S[ii]=='R'){
        cout << "No" << endl;
        return 0;
    }else{
      if(S[ii]=='L'){
        cout << "No" << endl;
        return 0;
      }
    }
  }
  cout << "Yes" << endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:21:2: error: expected '}' at end of input
   21 | }
      |  ^
a.cc:4:11: note: to match this '{'
    4 | int main(){
      |           ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  string s;
  cin >> s;
  
  bool ans = true;
  for (int i = 0; i < s.size(); i++){
    if((i % 2 == 0) && (s.at(i) == "L")){
      ans = false;
    }
    
    else if((i % 2 == 1) && (s.at(i) == "R")){
      ans = false;
    }
  }
  
  if(ans){
    cout << "Yes" <<endl;
  }
  
  else{
    cout << "No" << endl;
  }
    
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:33: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |     if((i % 2 == 0) && (s.at(i) == "L")){
      |                         ~~~~~~~~^~~~~~
a.cc:14:38: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   14 |     else if((i % 2 == 1) && (s.at(i) == "R")){
      |                              ~~~~~~~~^~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  string s;
  cin >> s;
  
  bool ans = true;
  for (int i = 0; i < s.size(); i++){
    if(i % 2 == 0 && s.at(i) == "L"){
      ans = false;
    }
    
    else if(i % 2 == 1 && s.at(i) == "R"){
      ans = false;
    }
  }
  
  if(ans){
    cout << "Yes" <<endl;
  }
  
  else{
    cout << "No" << endl;
  }
    
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:30: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |     if(i % 2 == 0 && s.at(i) == "L"){
      |                      ~~~~~~~~^~~~~~
a.cc:14:35: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   14 |     else if(i % 2 == 1 && s.at(i) == "R"){
      |                           ~~~~~~~~^~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  string vec;
  cin >> s;
  
  bool ans = true;
  for (int i = 0; i < s.size(); i++){
    if(i % 2 == 0 && s.at(i) == "L"){
      ans = false;
    }
    
    else if(i % 2 == 1 && s.at(i) == "R"){
      ans = false;
    }
  }
  
  if(ans){
    cout << "Yes" <<endl;
  }
  
  else{
    cout << "No" << endl;
  }
    
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:10: error: 's' was not declared in this scope
    6 |   cin >> s;
      |          ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  string s;
  cin >> s;
  string ans = "Yes";
  for(int i=0;i<s.size();++i){
    if((i%2==0&&s[i]=="L")||(i%2==1&&s[i]=="R")){
      ans="No";
      break;
    }
  }
  cout << ans << endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:21: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    9 |     if((i%2==0&&s[i]=="L")||(i%2==1&&s[i]=="R")){
a.cc:9:42: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    9 |     if((i%2==0&&s[i]=="L")||(i%2==1&&s[i]=="R")){
Language: C

#include<stdio.h>

int main(){
char S[100];
int f=0;
  scanf("%s",S);
  for(int i=0;S[i]!='\0';i++){
    if(i%2==1 && S[i]=='L'){
		f=1;
        break;
    }
    else if(S[i]=='R'){
    	f=1;
        break;
    }
  }
  if(f==1)printf("No\n")
  else printf("Yes\n");
  return 0;
}


Compiler output:
main.c: In function 'main':
main.c:17:25: error: expected ';' before 'else'
   17 |   if(f==1)printf("No\n")
      |                         ^
      |                         ;
   18 |   else printf("Yes\n");
      |   ~~~~
Language: C

#include<stdio.h>

int main(){
char S[100];
int f=0;
  scanf("%s",S);
  for(int i=0;S[i]!='\0';i++){
    if(i%2==1 && S[i]==L){
		f=1;
        break;
    }
    else if(S[i]==R){
    	f=1;
        break;
    }
  }
  if(f==1)printf("No\n")
  else printf("Yes\n");
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:8:24: error: 'L' undeclared (first use in this function)
    8 |     if(i%2==1 && S[i]==L){
      |                        ^
main.c:8:24: note: each undeclared identifier is reported only once for each function it appears in
main.c:12:19: error: 'R' undeclared (first use in this function)
   12 |     else if(S[i]==R){
      |                   ^
main.c:17:25: error: expected ';' before 'else'
   17 |   if(f==1)printf("No\n")
      |                         ^
      |                         ;
   18 |   else printf("Yes\n");
      |   ~~~~
Language: C++

//------------------------------------------------------------------------------MANAS UNIYAL---------------------------------------------------------
//																				NEVER GIVE UP
#include<bits/stdc++.h>
using namespace std;
#define fast ios_base::sync_with_stdio(false);	cin.tie(NULL);	cout.tie(NULL);
#define ll long long
#define pb push_back
#define fi first
#define se second
#define pii pair<ll,ll>
#define INF 0x3f3f3f3f
#define mod 100000007
#define testcases() ll t; cin>>t; while(t--)
#define debug1(x) cout<<#x<<" "<<x<<"\n";
#define debug2(x,y) cout<<#x<<" "<<x<<" "<<#y<<" "<<y<<"\n";
#define debug3(x,y,z) cout<<#x<<" "<<x<<" "<<#y<<" "<<y<<" "<<#z<<" "<<z<<"\n";
#define rep(i,start,end) for(ll i=start;i<end;i++)
 
//----------------------------------------------------------------------------------------------------------------------------------------------------

int main()
{
	fast;
	string str;
	cin>>str;
	for(int i=0;i<(int)str.size();i++)
	{
		if(i%2==0 && str[i]=='L')
		{
			flag = false;
			break;
		}
		else if(i%2==1 && str[i]=='R')
		{
			flag = false;
			break;
		}
	}
	flag?cout<<"Yes":cout<<"No";
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:30:25: error: 'flag' was not declared in this scope
   30 |                         flag = false;
      |                         ^~~~
a.cc:35:25: error: 'flag' was not declared in this scope
   35 |                         flag = false;
      |                         ^~~~
a.cc:39:9: error: 'flag' was not declared in this scope
   39 |         flag?cout<<"Yes":cout<<"No";
      |         ^~~~
Language: C++

#include<bits/stdc++>
using namespace std;

int main(){
  string S;
  cin >> S;
  int count =0;
  for(int i=0;i<S.size();i++){
  	if(i%2 == 0 && S.at(i) != 'L'){
  		count++;
  	}
  	else if(i%2 == 1 && S.at(i) != 'R'){
  		count++;
  	}
  	else{
  		cout << "No" <<endl;
  		break;
  	}
  }
  if(count == S.size()){
  	cout << "Yes" << endl;
  }
  return 0;
}

Compiler output:
a.cc:1:9: fatal error: bits/stdc++: No such file or directory
    1 | #include<bits/stdc++>
      |         ^~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
  string S;
  cin >> S;
  bool ans = false;
  for (int i = 0; i < S.size(); i++){
    if(i % 2 == 0){
      if(S.at(i) == 'L'){
        ans = true;
      }
    }
    else {
      if(S.at(i) == 'R'){
        ans = true;
      }
  }
    if (ans) cout << "No" << endl;
    else cout << "Yes" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:20:2: error: expected '}' at end of input
   20 | }
      |  ^
a.cc:3:11: note: to match this '{'
    3 | int main(){
      |           ^
Language: C

#include<stdio.h>
 
int main(){
  char str[];
  scanf("%s",str);
  if(str[]== Sunny)
    printf("Cloudy");
  
  else if(str[]==Cloudy)
    printf("Rainy");
  
  else
    printf("Sunny");
  
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:8: error: array size missing in 'str'
    4 |   char str[];
      |        ^~~
main.c:6:10: error: expected expression before ']' token
    6 |   if(str[]== Sunny)
      |          ^
main.c:9:15: error: expected expression before ']' token
    9 |   else if(str[]==Cloudy)
      |               ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  string S;
  cin >> S;
  double a = S.size();
  int b=0;
  for(x=0; x<a; x+=2){
  if(S.at(x) == 'L'){
  b++;
  break;
  }
  for(x=1; x<a; x+=2){
  if(S.at(x) == 'R'){
  b++;
  break;
  }
  }
if(b == 0) cout << "Yes" << endl;
    else cout << "No" << endl;
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:7: error: 'x' was not declared in this scope
    9 |   for(x=0; x<a; x+=2){
      |       ^
Language: Java

import java.util.Scanner;

public class Main{
  public static void main(String args[]){
    Scanner sc = new Scanner(System.in);
    String a = sc.next();
    char[] b = a.toCharArray();
    String c = "Yes";
    for(i = 0;i < b.length;i++){
      if(i % 2 == 0 && char[i] != 'L' || char[i] != 'U' ||  char[i] != 'D' ){
        c = "No"; 
      }else if(i % 2 == 1 && char[i] != 'R' || char[i] != 'U' ||  char[i] != 'D' ){
        c = "No"; 
    }
      System.out.println(c);
  }
}

Compiler output:
Main.java:10: error: ']' expected
      if(i % 2 == 0 && char[i] != 'L' || char[i] != 'U' ||  char[i] != 'D' ){
                            ^
Main.java:10: error: ';' expected
      if(i % 2 == 0 && char[i] != 'L' || char[i] != 'U' ||  char[i] != 'D' ){
                             ^
Main.java:10: error: ']' expected
      if(i % 2 == 0 && char[i] != 'L' || char[i] != 'U' ||  char[i] != 'D' ){
                                              ^
Main.java:10: error: ';' expected
      if(i % 2 == 0 && char[i] != 'L' || char[i] != 'U' ||  char[i] != 'D' ){
                                               ^
Main.java:10: error: ']' expected
      if(i % 2 == 0 && char[i] != 'L' || char[i] != 'U' ||  char[i] != 'D' ){
                                                                 ^
Main.java:10: error: ';' expected
      if(i % 2 == 0 && char[i] != 'L' || char[i] != 'U' ||  char[i] != 'D' ){
                                                                  ^
Main.java:12: error: ']' expected
      }else if(i % 2 == 1 && char[i] != 'R' || char[i] != 'U' ||  char[i] != 'D' ){
                                  ^
Main.java:12: error: ';' expected
      }else if(i % 2 == 1 && char[i] != 'R' || char[i] != 'U' ||  char[i] != 'D' ){
                                   ^
Main.java:12: error: 'else' without 'if'
      }else if(i % 2 == 1 && char[i] != 'R' || char[i] != 'U' ||  char[i] != 'D' ){
       ^
Main.java:12: error: ']' expected
      }else if(i % 2 == 1 && char[i] != 'R' || char[i] != 'U' ||  char[i] != 'D' ){
                                                    ^
Main.java:12: error: ';' expected
      }else if(i % 2 == 1 && char[i] != 'R' || char[i] != 'U' ||  char[i] != 'D' ){
                                                     ^
Main.java:12: error: ']' expected
      }else if(i % 2 == 1 && char[i] != 'R' || char[i] != 'U' ||  char[i] != 'D' ){
                                                                       ^
Main.java:12: error: ';' expected
      }else if(i % 2 == 1 && char[i] != 'R' || char[i] != 'U' ||  char[i] != 'D' ){
                                                                        ^
Main.java:17: error: reached end of file while parsing
}
 ^
14 errors
Language: C++

 #include <iostream>
 #include <string>
#include <cstdio>
 using namespace std;
 int main(){
 string s;
 for (int i=0;i<100;i++){
    cin>>s;
   if(i%2){
if(s=="L"){cout<<"No"<<endl; return 0;}
  
   }else{
   if(s=="R"){cout<<"No"<<endl; return 0;}
  
   
   }
   cout<<"Yes"<<endl;

 return 0;
 }


Compiler output:
a.cc: In function 'int main()':
a.cc:20:3: error: expected '}' at end of input
   20 |  }
      |   ^
a.cc:5:12: note: to match this '{'
    5 |  int main(){
      |            ^
Language: Java

import java.util.Scanner;

public class Main{

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		char [] a = sc.next().toCharArray();
		int b = 0;
		int c = 0;
		
		for(int i = 0; i <= a.length; i+=2) {
			if(a[i]=='R' || a[i]=='U' || a[i]=='D') {//奇数の条件
				b++;
			}else {
				b=0;
				break;
			}
		}
		
		for(int j = 1; j < =a.length; j+=2) {
			if(a[j]=='L' || a[j]=='U' || a[j]=='D') {//偶数の条件
				c++;
			}else {
				c=0;
				break;
			}
		}

		if(b ==0 || c == 0) {
			System.out.println("No");
		}else {
			System.out.println("Yes");
		}




	}

}


Compiler output:
Main.java:21: error: illegal start of expression
		for(int j = 1; j < =a.length; j+=2) {
		                   ^
1 error
Language: C

#include<stdio.h>
 
int main(){
  int n,x,y;
  scanf("%d",&n); 
  n <= 2*x;
  n <= 2*x+1;
  char S[n];
  
  for(x=0;2*x<=n;x++){
  	for(x=0;2*x+1<=n;x++){
  	  scanf("%d",&x);
	    if(S[2*x+1]="L"| S[2*x]="L")
    	  printf("No");
   	    else
      	  printf("Yes");
  
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:13:28: error: invalid operands to binary | (have 'char *' and 'int')
   13 |             if(S[2*x+1]="L"| S[2*x]="L")
      |                         ~~~^ ~~~~~~
      |                         |     |
      |                         |     char
      |                         char *
main.c:19:1: error: expected declaration or statement at end of input
   19 | }
      | ^
main.c:19:1: error: expected declaration or statement at end of input
Language: C

#include<stdio.h>
 
int main(){
  int n,x,y;
  scanf("%d",&n); 
  n <= 2*x;
  n <= 2*x+1;
  char S[n];
  
  for(x=0;2*x<=n;x++){
  	for(x=0;2*x+1<=n;x++){
  	  scanf("%d",&x);
	    if(S[2*x+1]=L | S[2*x]=L)
    	  printf("No");
   	    else
      	  printf("Yes");
  
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:13:25: error: 'L' undeclared (first use in this function)
   13 |             if(S[2*x+1]=L | S[2*x]=L)
      |                         ^
main.c:13:25: note: each undeclared identifier is reported only once for each function it appears in
main.c:19:1: error: expected declaration or statement at end of input
   19 | }
      | ^
main.c:19:1: error: expected declaration or statement at end of input
Language: C

#include<stdio.h>

int main(){
  int n,x,y;
  n <= 2x;
  n <= 2x+1;
  scanf("%d",&x);
  char S[n];
  
  
  if(S[2x+1]=L | S[2x]=L) 
  	printf("No");
  else
    printf("Yes");
  
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:8: error: invalid suffix "x" on integer constant
    5 |   n <= 2x;
      |        ^~
main.c:6:8: error: invalid suffix "x" on integer constant
    6 |   n <= 2x+1;
      |        ^~
main.c:11:8: error: invalid suffix "x" on integer constant
   11 |   if(S[2x+1]=L | S[2x]=L)
      |        ^~
main.c:11:14: error: 'L' undeclared (first use in this function)
   11 |   if(S[2x+1]=L | S[2x]=L)
      |              ^
main.c:11:14: note: each undeclared identifier is reported only once for each function it appears in
main.c:11:20: error: invalid suffix "x" on integer constant
   11 |   if(S[2x+1]=L | S[2x]=L)
      |                    ^~
Language: Java

import java.util.Scanner;

public class TapDance{
    public static void main(String[] args){
        String S = new Scanner(System.in).nextLine();
        int i=0;
        while(i<S.length()){
            //System.out.println(i);
            if(S.charAt(i)!='R' && S.charAt(i)!='U' && S.charAt(i)!='D'){
                System.out.println("No");
                System.exit(0);
            }
            i+=2;
        }
        i=1;
        while(i<S.length()){
            //System.out.println(i);
            if(S.charAt(i)!='L' && S.charAt(i)!='U' && S.charAt(i)!='D'){
                System.out.println("No");
                System.exit(0);
            }
            i+=2;
        }
        System.out.println("Yes");
    }
} 

Compiler output:
Main.java:3: error: class TapDance is public, should be declared in a file named TapDance.java
public class TapDance{
       ^
1 error
Language: C++

#include <bits/stdc++.h>

using namespace std;

int main(){
  string s;
  cin >> s;
  string a="Yes";
  for(int i=0;i<s.size();i++){
    if(i%2==0){
      if(s[i]=='L'){
        a="No";
      }
    }
    else{
      if(s[i]=='R'){
        a="No";
      }
    }
    cout << a << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:21:2: error: expected '}' at end of input
   21 | }
      |  ^
a.cc:5:11: note: to match this '{'
    5 | int main(){
      |           ^
Language: C++

#include<iostream>
#include<string>

int main(void)
{
  std::string str;
  
  std::cin >> str;
  for(int index = 0; str.size() > index; ++index)
  {
    if()
    {
      if(('R' == c && 0 == index % 2) || ('L' == c && 1 == index % 2))
      {
        std::cout << "No";
        return 0;
      }
    }
  }
  std::cout << "Yes";
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:8: error: expected primary-expression before ')' token
   11 |     if()
      |        ^
a.cc:13:18: error: 'c' was not declared in this scope
   13 |       if(('R' == c && 0 == index % 2) || ('L' == c && 1 == index % 2))
      |                  ^
Language: C++

#include<bits/stdc++.h>
using namespace std;

int main()
{
  String a;
  gets(a);
  for(i=0;a[i]!='\0';i++)
  {
    if(((i%2==0) && (a[i]=='R' || a[i]== 'U' || a[i] == 'D')) || ((i%2!=1) && (a[i]=='L' || a[i]== 'U' || a[i] == 'D')))
      continue;
    else
    {cout<<"No"<<endl;return 0;}
  }
  cout<<"Yes"<<endl; return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:3: error: 'String' was not declared in this scope
    6 |   String a;
      |   ^~~~~~
a.cc:7:8: error: 'a' was not declared in this scope
    7 |   gets(a);
      |        ^
a.cc:7:3: error: 'gets' was not declared in this scope; did you mean 'getw'?
    7 |   gets(a);
      |   ^~~~
      |   getw
a.cc:8:7: error: 'i' was not declared in this scope
    8 |   for(i=0;a[i]!='\0';i++)
      |       ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
  int cnt=0;
  string s;
  cin>>s;
  for(int i=0;i<s.length();i++)
  {   
     if(i%2!=0)
     {
       if(s[i]=='L' || s[i]=='U'|| s[i]=='D')
       {
         cnt++;
       }
     }
    else
    {
      if(s[i]=='R' || s[i]=='U'|| s[i]=='D')
       {
         cnt++;
       }
    }  
  }
 if(cnt==s.lenght())
 {
   cout<<"Yes";
 }
 else
 {
   cout<<"No";
 }
   return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:25:12: error: 'std::string' {aka 'class std::__cxx11::basic_string<char>'} has no member named 'lenght'; did you mean 'length'?
   25 |  if(cnt==s.lenght())
      |            ^~~~~~
      |            length
Language: C++

import java.util.Scanner;
public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner (System.in);
        String s =sc.next();
        boolean b = false;
        for(int i = 0 ; i<s.length(); i++){
             if(i%2==0){
                 
                // System.out.println("just watching the odd index of the string  "+ i);
               //  System.out.println(s.charAt(i));
                 if(s.charAt(i)==('R'|'U'|'D'))
                     b = true;
             }
             if(b==true)
             {    
                 if(i%2==1){
                    // System.out.println("just checking the even idex  "+ i);
                    // System.out.println(s.charAt(i));
                     if(s.charAt(i)==('L'|'U'|'D'))
                         b = true;
                 }
             }
            
            
        }
        if(b==true) System.out.println("YES");
        else System.out.println("NO");
    }
}


Compiler output:
a.cc:1:1: error: 'import' does not name a type
    1 | import java.util.Scanner;
      | ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:2:1: error: expected unqualified-id before 'public'
    2 | public class Main {
      | ^~~~~~
Language: C++

#include<iostream>
#include<string>
using namespace std;

int main()
{
    string S;
    bool flag = true;
    cin>>S;
    for(int i=0;i<static_cast<int>(S.length());i++){
        if(i%2==0){
            if(S[i]=='L')flag = false;
        }else{
            if(S[i]=='R')flag = false;
        }
    }
    if(flag)cout<<"Yes"<<endl;
    else cout<<"No"<<endl;
}
}

Compiler output:
a.cc:20:1: error: expected declaration before '}' token
   20 | }
      | ^
Language: C++

#include<iostream>
#include<string>
using namespace std;

int main()
{
    string S;
    bool flag = true;
    cin>>S;
    for(int i=0;i<(static_cast<int>(S.length())+1)/2;i+=2){
        if(S[i] == 'L'||S[i+1]== 'R')flag = false;
    }
    if(flag){
        cout<<"Yes"<<endl;
    }else{
        cout<<"No"<<endl;
    }
}
}

Compiler output:
a.cc:19:1: error: expected declaration before '}' token
   19 | }
      | ^
Language: C++

#include<iostream>
using namespace std;
#define ll long long

int main() {
  std::string S;
  cin >> S;
  bool retbool = true;
  for (ll i = 0; i < S.size(); ++l) {
    if (i%2==0) retbool = (S[i] == "R") ? false : true;
    else retbool = (S[i] == "L") ? false : true;
    
    if (retbool == false) break;
  }
  cout << (retbool) ? "Yes" : "No" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:34: error: 'l' was not declared in this scope
    9 |   for (ll i = 0; i < S.size(); ++l) {
      |                                  ^
a.cc:10:33: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |     if (i%2==0) retbool = (S[i] == "R") ? false : true;
a.cc:11:26: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   11 |     else retbool = (S[i] == "L") ? false : true;
a.cc:15:36: error: invalid operands of types 'const char [3]' and '<unresolved overloaded function type>' to binary 'operator<<'
   15 |   cout << (retbool) ? "Yes" : "No" << endl;
      |                               ~~~~~^~~~~~~
Language: C++

#include <iostream>
#Define rep(i,n) for(int i = 0;i<n;i++)
using namespace std;

int main() {
  string s;
  cin >> s;
  int n = s.size();
  bool ok = true;
  rep(i,n) {
    if (i%2 == 0 && s[i] == 'L') ok = false;
    if (i%2 == 1 && s[i] == 'R') ok = false;
  }
  if (ok) puts("Yes"); else puts("No");
  return 0;
}

Compiler output:
a.cc:2:2: error: invalid preprocessing directive #Define; did you mean #define?
    2 | #Define rep(i,n) for(int i = 0;i<n;i++)
      |  ^~~~~~
      |  define
a.cc: In function 'int main()':
a.cc:10:7: error: 'i' was not declared in this scope
   10 |   rep(i,n) {
      |       ^
a.cc:10:3: error: 'rep' was not declared in this scope
   10 |   rep(i,n) {
      |   ^~~
Language: C++

#include <iostream>
#include <string>
using namespace std;

int main(){
  string str;
  bool ans = true; 
  cin >> str;
  int s = str.size();
  for(int i = 0;i < s;i++){
    if(i % 2 == 0 %% str[i] == 'L')
      ans = false;
    if(i % 2 == 1 %% str[i] == 'R')
      ans = false;
  }
  if(ans == true) puts("Yes")
  else; puts("No")
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:11:20: error: expected primary-expression before '%' token
   11 |     if(i % 2 == 0 %% str[i] == 'L')
      |                    ^
a.cc:13:20: error: expected primary-expression before '%' token
   13 |     if(i % 2 == 1 %% str[i] == 'R')
      |                    ^
a.cc:16:30: error: expected ';' before 'else'
   16 |   if(ans == true) puts("Yes")
      |                              ^
      |                              ;
   17 |   else; puts("No")
      |   ~~~~                        
a.cc:17:19: error: expected ';' before 'return'
   17 |   else; puts("No")
      |                   ^
      |                   ;
   18 |   return 0;
      |   ~~~~~~
Language: C++

#include <iostream>
#include <string>
using namespace std;

int main(){
  string str;
  string str1;
  string str2;
  bool ans = true; 
  cin >> str;
  size_t size = str.length();
  for(int i = 0;i < size;i++){
    if(i % 2 == 0)
      str1 += str[i];
    else if (i % 2 == 1)
      str2 += str[i];
  }
  for(int j = 0;j < size;j++){
    if(str1[j] == 'L')
      ans = false;
    else if(str2[j] == 'R')
      ans = false;
  }
  if(ans == true) 
    puts("Yes");
  else;
    puts("No;")
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:27:16: error: expected ';' before 'return'
   27 |     puts("No;")
      |                ^
      |                ;
   28 |   return 0;
      |   ~~~~~~
Language: C++

#include<iostream>
using namespace std;

int main()
{
	char S[105];
	int n;

	cin >> S;

	n = strlen(S);
	for (int i = 0; i < n; i++) {
		if (i % 2 == 0) {
			if (S[i] == 'R') {
				cout << 'No' << endl;
				return 0;
			}
		}
		else {
			if (S[i] == 'L') {
				cout << 'No' << endl;
				return 0;
			}
		}
	}

	cout << 'Yes' << endl;
	return 0;


}

Compiler output:
a.cc:15:41: warning: multi-character character constant [-Wmultichar]
   15 |                                 cout << 'No' << endl;
      |                                         ^~~~
a.cc:21:41: warning: multi-character character constant [-Wmultichar]
   21 |                                 cout << 'No' << endl;
      |                                         ^~~~
a.cc:27:17: warning: multi-character character constant [-Wmultichar]
   27 |         cout << 'Yes' << endl;
      |                 ^~~~~
a.cc: In function 'int main()':
a.cc:11:13: error: 'strlen' was not declared in this scope
   11 |         n = strlen(S);
      |             ^~~~~~
a.cc:2:1: note: 'strlen' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    1 | #include<iostream>
  +++ |+#include <cstring>
    2 | using namespace std;
Language: C++

#include <iostream>
#include <string>
using namespace std;

int main(){
  string str;
  string str1;
  string str2;
  cin >> str;
  size_t size = str.length();
  for(int i = 0;i < size;i++){
    if(i % 2 == 0)
      str1 += str[i];
    else;
      str2 += str[i];
  }
  for(int i = 0;i < size + 1;i++){
    if(str1[i] == "L")
      cout << "No" << endl;
    else if(str2[i] == "R")
      cout << "No" << endl;
    else;
      cout << "Yes" << endl;
  }
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:18:16: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   18 |     if(str1[i] == "L")
a.cc:20:21: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   20 |     else if(str2[i] == "R")
Language: C++

#include <iostream>
#include <string>
using namespace std;

int main(){
  string str;
  string str1;
  string str2;
  cin >> str;
  size_t size = str.length();
  for(int i = 0;i < size;i++){
    if(i % 2 == 0)
      str1 += str[i];
    else;
      str2 += str[i];
  }
  for(int i = 0;i < size + 1;i++){
    if(str1.at(i) == "L")
      cout << "No" << endl;
    else if(str2.at(i) == "R")
      cout << "No" << endl;
    else;
      cout << "Yes" << endl;
  }
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:18:19: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   18 |     if(str1.at(i) == "L")
      |        ~~~~~~~~~~~^~~~~~
a.cc:20:24: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   20 |     else if(str2.at(i) == "R")
      |             ~~~~~~~~~~~^~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
string s;
int main(){
    cin >> s;
    for (int i=0; i<s.length(); i++){
        if ( (i%2==0 && strcmp(s[i],"R")) || (i%2==1 && strcmp(s[i],"L")) ){
            cout << "No";
            return 0;
        }
    }
    cout << "Yes";
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:31: error: invalid conversion from '__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type' {aka 'char'} to 'const char*' [-fpermissive]
    7 |         if ( (i%2==0 && strcmp(s[i],"R")) || (i%2==1 && strcmp(s[i],"L")) ){
      |                         ~~~~~~^~~~~~~~~~
      |                               |
      |                               __gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type {aka char}
In file included from /usr/include/c++/14/cstring:43,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:121,
                 from a.cc:1:
/usr/include/string.h:156:32: note:   initializing argument 1 of 'int strcmp(const char*, const char*)'
  156 | extern int strcmp (const char *__s1, const char *__s2)
      |                    ~~~~~~~~~~~~^~~~
a.cc:7:63: error: invalid conversion from '__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type' {aka 'char'} to 'const char*' [-fpermissive]
    7 |         if ( (i%2==0 && strcmp(s[i],"R")) || (i%2==1 && strcmp(s[i],"L")) ){
      |                                                         ~~~~~~^~~~~~~~~~
      |                                                               |
      |                                                               __gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type {aka char}
/usr/include/string.h:156:32: note:   initializing argument 1 of 'int strcmp(const char*, const char*)'
  156 | extern int strcmp (const char *__s1, const char *__s2)
      |                    ~~~~~~~~~~~~^~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
string s;
int main(){
    cin >> s;
    for (int i=0; i<s.length(); i++){
        if ( (i%2==0 && s[i]=="R") || (i%2==1 && s[i]=="L") ){
            cout << "No";
            return 0;
        }
    }
    cout << "Yes";
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:29: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    7 |         if ( (i%2==0 && s[i]=="R") || (i%2==1 && s[i]=="L") ){
a.cc:7:54: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    7 |         if ( (i%2==0 && s[i]=="R") || (i%2==1 && s[i]=="L") ){
Language: C++

#include <bits/stdc++.h>
using namespace std;
string s;
int main(){
    cin >> s;
    for (int i=0; i<s.length(); i++){
        if ( (i%2==0 and s[i]=="R") or (i%2==1 and s[i]=="L") ){
            cout << "No";
            return 0;
        }
    }
    cout << "Yes";
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:30: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    7 |         if ( (i%2==0 and s[i]=="R") or (i%2==1 and s[i]=="L") ){
a.cc:7:56: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    7 |         if ( (i%2==0 and s[i]=="R") or (i%2==1 and s[i]=="L") ){
Language: C++

#include <bits/stdc++.h>
using namespace std;
int s;
int main(){
    cin >> s;
    for (int i=0; i<s.length(); i++){
        if ( (i%2==0 and s[i]=="R") or (i%2==1 and s[i]=="L") ){
            cout << "No";
            return 0;
        }
    }
    cout << "Yes";
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:23: error: request for member 'length' in 's', which is of non-class type 'int'
    6 |     for (int i=0; i<s.length(); i++){
      |                       ^~~~~~
a.cc:7:27: error: invalid types 'int[int]' for array subscript
    7 |         if ( (i%2==0 and s[i]=="R") or (i%2==1 and s[i]=="L") ){
      |                           ^
a.cc:7:53: error: invalid types 'int[int]' for array subscript
    7 |         if ( (i%2==0 and s[i]=="R") or (i%2==1 and s[i]=="L") ){
      |                                                     ^
Language: C++

#include <bits/stdc++.h>
#include <algorithm>
using namespace std;
int main() {
string a;
  
 
  cin >> a ;

  for(int i=1;i<=a.size();i++){
    if((i%2 ==0)&&(a[i] == "R")){
      cout << "No" << endl;
      
      return 0;
    }
    if((i%2 == 1)&&(a[i] == "L")){
      cout << "No" << endl;
      
      return 0;
    }
  }
  
  cout <<"Yes" << endl;
}
    


Compiler output:
a.cc: In function 'int main()':
a.cc:11:25: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   11 |     if((i%2 ==0)&&(a[i] == "R")){
a.cc:16:26: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   16 |     if((i%2 == 1)&&(a[i] == "L")){
Language: C++

#include <bits/stdc++.h>
#include <algorithm>
using namespace std;
int main() {
string a;
  
 
  cin >> a ;

  for(int i=1;i<=a.size();i++){
    if((i%2 ==0)&&(s[i] == "R")){
      cout << "No" << endl;
      
      return 0;
    }
    if((i%2 == 1)&&(s[i] == "L")){
      cout << "No" << endl;
      
      return 0;
    }
  }
  
  cout <<"Yes" << endl;
}
    

Compiler output:
a.cc: In function 'int main()':
a.cc:11:20: error: 's' was not declared in this scope
   11 |     if((i%2 ==0)&&(s[i] == "R")){
      |                    ^
a.cc:16:21: error: 's' was not declared in this scope
   16 |     if((i%2 == 1)&&(s[i] == "L")){
      |                     ^
Language: C++

#include <iostream>
#include<bits/stdc++.h>
using namespace std;
int main() {
	// your code goes here
	string s;
	int l,t1=0,t2=0;
	cin>>s;
	l=s.length();
	//cout<<l<<endl;
	for(int i=0;i<l;i++)
	{
	 if(i%2==0)
	 {
	    if(s[i]=='R'||s[i]=='U'||s[i]=='D')
	     {
	         t1=1;
	        
	     }
	     else 
	     {
	         t1=0;
	         break;
	     }
	 }
	 else
	 {
	    if(s[i]=='L'||s[i]=='U'||s[i]=='D')
	     {
	         t2=1;
	         char c=s[i];
	       
	     }
	     else 
	     {
	         t2=0;
	         
	         break;
	     } 
	 }
	}
	if((t1==1)&&(t2==1))
	cout<<"Yes"<<endl;
	else
	cout<<"No<<endl;
	
	return 0;
}

Compiler output:
a.cc:45:15: warning: missing terminating " character
   45 |         cout<<"No<<endl;
      |               ^
a.cc:45:15: error: missing terminating " character
   45 |         cout<<"No<<endl;
      |               ^~~~~~~~~~
a.cc: In function 'int main()':
a.cc:47:9: error: expected primary-expression before 'return'
   47 |         return 0;
      |         ^~~~~~
Language: C

#include <stdio.h>

int main(void){
  int a=1;
  char s[100];
  int i=0;
  while(1){
	scanf("%c",%s[i]);
    if(s[i]!='L'&&s[i]!='R'&&s[i]!='U'&&s[i]!='D')break;
    if(i%2==1){
      if(s[i]=='R')a=0;
    }
    else{
      if(s[i]=='L')a=0;
    }
    i++;
  }
  if(a==0)printf("No\n");
  else printf("Yes\n");
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:8:20: error: expected expression before '%' token
    8 |         scanf("%c",%s[i]);
      |                    ^
Language: C

#include <stdio.h>

int main(void){
  int a=1;
  char s[100];
  int i=0;
  while(1){
	scanf("%c",%s[i]);
    if(s[i]!='L'||s[i]!='R'||s[i]!='U'||s[i]!='D')break;
    if(i%2==0){
      if(s[i]=='R')a=0;
    }
    else{
      if(s[i]=='L')a=0;
    }
  }
  if(a==0)printf("No¥n");else printf("Yes\n");
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:8:20: error: expected expression before '%' token
    8 |         scanf("%c",%s[i]);
      |                    ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  vector<string> vec(N);
  for (int i = 0; i < N; i++) {
    cin >> vec.at(i);
  }

  string s;
  cin>>s;
  string a="Yes";
  int i;
  if(i%2==0){
    if(s.at(i)=='L'){
    a="No";
    }
  }
  if(i%2==1){
    if(s.at(i)=='R'){
    a="No";
    }
  }
  cout<<a<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:22: error: 'N' was not declared in this scope
    5 |   vector<string> vec(N);
      |                      ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  string s;
  cin>>s;
  string a="Yes";
  int i;
  if(i%2==0&&s.at(i)=="L"){
    a="No";
  }
  if(i%2==1&&s.at(i)=="R"){
    a="No";
  }
  cout<<a<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:21: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    9 |   if(i%2==0&&s.at(i)=="L"){
      |              ~~~~~~~^~~~~
a.cc:12:21: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   12 |   if(i%2==1&&s.at(i)=="R"){
      |              ~~~~~~~^~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  string move;
  cin >> move;
  int a = 0;

  for(int i = 0; i < move.size(); i+=2){
      if(move[i] == 'S' || 'U' || 'D'){
        break;
      }
      else{
        a += 1;
      }     
    }
  for(int i = 0; i < move.size(); i+=2){
      if(move[i] == 'L' || 'U' || 'D'){
        break;
      }
      else{
        a += 1;
      }
    }
    if(a >= 1){
        cout << "No";
    }
    if(a == 0)
        cout << "Yes";
    }
}

Compiler output:
a.cc:31:1: error: expected declaration before '}' token
   31 | }
      | ^
Language: C++

#include<iostream>
using namespace std;
int main()
{ int i=0;
  string S;
  cin>>S;
  while(S[i]!='\0')
  {
   if(i%2==0&&S[i]=='R')
   { cout<<"No"'
     break;
   }
   else if(S[i]=='L'&&i%2!=0)
   {
     cout<<"Yes";
     break;
   }
    i++;
  }
return 0;
}

Compiler output:
a.cc:10:16: warning: missing terminating ' character
   10 |    { cout<<"No"'
      |                ^
a.cc:10:16: error: missing terminating ' character
a.cc: In function 'int main()':
a.cc:10:16: error: expected ';' before 'break'
   10 |    { cout<<"No"'
      |                ^
      |                ;
   11 |      break;
      |      ~~~~~
Language: C++

#include<iostream>
using namespace std;
int main()
{ int i;
  string S;
  cin>>S;
  while(S[i]!='\0')
  {
   if(i%2==0&&S[i]=='R')
   { cout<<"No"'
     break;
   }
   else if(S[i]=='L'&&i%2!=0)
   {
     cout<<"Yes";
     break;
   }
    i++;
  }
return 0;
}

Compiler output:
a.cc:10:16: warning: missing terminating ' character
   10 |    { cout<<"No"'
      |                ^
a.cc:10:16: error: missing terminating ' character
a.cc: In function 'int main()':
a.cc:10:16: error: expected ';' before 'break'
   10 |    { cout<<"No"'
      |                ^
      |                ;
   11 |      break;
      |      ~~~~~