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

#include<iostream>
#include<string>
using namespace std;
int main(){
	map<char,int> cnt;
	string str;
	while(cin>>str){
		for(int i=0;i<str.size();i++){
			if(isupper(str[i])){
				str[i]=tolower(str[i]);
			}
		}
		for(int i=0;i<str.size();i++){
			cnt[str[i]]++;
		}
	}
		for(char c='a';c<='z';c++){
			cout<<c<<" : "<<cnt[c]<<endl;
		}
		
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:5:9: error: 'map' was not declared in this scope
    5 |         map<char,int> cnt;
      |         ^~~
a.cc:2:1: note: 'std::map' is defined in header '<map>'; this is probably fixable by adding '#include <map>'
    1 | #include<iostream>
  +++ |+#include <map>
    2 | #include<string>
a.cc:5:13: error: expected primary-expression before 'char'
    5 |         map<char,int> cnt;
      |             ^~~~
a.cc:14:25: error: 'cnt' was not declared in this scope; did you mean 'int'?
   14 |                         cnt[str[i]]++;
      |                         ^~~
      |                         int
a.cc:18:41: error: 'cnt' was not declared in this scope; did you mean 'int'?
   18 |                         cout<<c<<" : "<<cnt[c]<<endl;
      |                                         ^~~
      |                                         int
Language: C++

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

int main(){
	
	map < char , int > count;
	
	string mozi;
	
	while(cin>>mozi){
		
		for(int i=0;i<(int)mozi.size();i++){
		
		if(mozi[i] == isupper){
		mozi[i] = tolower(mozi[i]);
		}
		}
		
		for(int i=0;i<(int)mozi.size();i++){
		
		count[mozi[i]]++		
			
		}
		
		for(char ch="a";ch<="z";ch++){
			cout<<ch<<" : "<<count[ch]<<endl; 
			
		}
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:28: error: invalid operands of types '__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type' {aka 'char'} and '<unresolved overloaded function type>' to binary 'operator=='
   14 |                 if(mozi[i] == isupper){
a.cc:21:40: error: expected ';' before '}' token
   21 |                 count[mozi[i]]++
      |                                 ^       
      |                                        ;
   22 | 
   23 |                 }
      |                 ~                
a.cc:25:29: error: invalid conversion from 'const char*' to 'char' [-fpermissive]
   25 |                 for(char ch="a";ch<="z";ch++){
      |                             ^~~
      |                             |
      |                             const char*
a.cc:25:35: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   25 |                 for(char ch="a";ch<="z";ch++){
      |                                 ~~^~~~~
a.cc:30:2: error: expected '}' at end of input
   30 | }
      |  ^
a.cc:4:11: note: to match this '{'
    4 | int main(){
      |           ^
Language: C++

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

int main(){
	
	map < char , int > count;
	
	string mozi;
	
	while(cin>>mozi){
		
		for(int i=0;i<(int)mozi.size();i++){
		
		if(isupper(mozi[i])){
		mozi[i] = tolower(mozi[i]);
		}
		}
		
		for(int i=0;i<(int)mozi.size();i++){
		
		count[mozi[i]]++		
			
		}
		
		for(char ch="a";ch<="z";ch++){
			cout<<ch<<" : "<<count[ch]<<endl; 
			
		}
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:21:40: error: expected ';' before '}' token
   21 |                 count[mozi[i]]++
      |                                 ^       
      |                                        ;
   22 | 
   23 |                 }
      |                 ~                
a.cc:25:29: error: invalid conversion from 'const char*' to 'char' [-fpermissive]
   25 |                 for(char ch="a";ch<="z";ch++){
      |                             ^~~
      |                             |
      |                             const char*
a.cc:25:35: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   25 |                 for(char ch="a";ch<="z";ch++){
      |                                 ~~^~~~~
a.cc:30:2: error: expected '}' at end of input
   30 | }
      |  ^
a.cc:4:11: note: to match this '{'
    4 | int main(){
      |           ^
Language: C++

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

int main(){
	
	map < char , int > count;
	
	string mozi;
	
	while(cin>>mozi){
		
		for(int i=0;i<(int)mozi.size();i++){
		
		if(isupper(mozi[i])){
		mozi[i] = tolower(mozi[i]);
		}
		}
		
		for(int i=0;i<(int)mozi.size();i++){
		
		count[mozi[i]]++;		
			
		}
		
		for(char ch="a";ch<="z";ch++){
			cout<<ch<<" : "<<count[ch]<<endl; 
			
		}
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:25:29: error: invalid conversion from 'const char*' to 'char' [-fpermissive]
   25 |                 for(char ch="a";ch<="z";ch++){
      |                             ^~~
      |                             |
      |                             const char*
a.cc:25:35: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   25 |                 for(char ch="a";ch<="z";ch++){
      |                                 ~~^~~~~
a.cc:30:2: error: expected '}' at end of input
   30 | }
      |  ^
a.cc:4:11: note: to match this '{'
    4 | int main(){
      |           ^
Language: C++

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

int main(){
	
	map < char , int > count;
	
	string mozi;
	
	while(cin>>mozi){
		
		for(int i=0;i<(int)mozi.size();i++){
		
		if(isupper(mozi[i])){
		mozi[i] = tolower(mozi[i]);
		}
		}
		
		for(int i=0;i<(int)mozi.size();i++){
		
		count[mozi[i]]++;		
			
		}
	}
		for(char ch="a";ch<="z";ch++){
			cout<<ch<<" : "<<count[ch]<<endl; 
			
		}
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:25:29: error: invalid conversion from 'const char*' to 'char' [-fpermissive]
   25 |                 for(char ch="a";ch<="z";ch++){
      |                             ^~~
      |                             |
      |                             const char*
a.cc:25:35: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   25 |                 for(char ch="a";ch<="z";ch++){
      |                                 ~~^~~~~
Language: C++

#include <iostream>
#include <vector>
#include <cstring>
#include <cctype>
#include <string>
using namespace std;

int main(){
	vector<int>a(26, 0);
	char st;
	while (cin>>st){
		if (isalpha(st)){
			if (isupper(st))
				st = tolower(st);
			a[st - 'a']++
		}
	}
	for (int i = 0; i <= 25; i++){
		cout << static_cast<char>(i + 'a') << " : " << a[i] << endl;
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:38: error: expected ';' before '}' token
   15 |                         a[st - 'a']++
      |                                      ^
      |                                      ;
   16 |                 }
      |                 ~
Language: C++

#include <iostream>
#include <string>
#include <cctype>

using namespace std;

int main()
{
	int counter[26];
	for (int i = 0; i < 26; ++i) counter[i] = 0;

	string x;
	while (cin >> x)
	{
		for (string::size_type i; i < x.size(); i++)
		{
			if (isupper(x[i])) x[i] = tolower(x[i]);
			if (isalpha) counter[x[i]-'a']++;
		}
	}

	for (int i = 0; i < 26; ++i)
		cout << (char)(i + 'a') << " : " << counter[i] << endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:36: error: cannot resolve overloaded function 'isalpha' based on conversion to type 'bool'
   18 |                         if (isalpha) counter[x[i]-'a']++;
      |                                    ^
Language: Java

import java.util.*;

class Main {
    public static void main(String args[]) {
        Scanner sc = new Scanner(System.in);
        String s = sc.nextLine();
        String p = sc.nextLine();
        String x = s + s;
        for(int ix = 0; ix < x.length(); ix++) {
            boolean b;
            for(int ip =0; ip < p.length(); ip++) {
                b = x.charAt(ix) == p.charAt(ip);
                if(b == false)
                    break;
            }
            if (b == true)
                break;
        }
        if(b)
            System.out.println("Yes");
        else
            System.out.println("No");
    }
}


Compiler output:
Main.java:19: error: cannot find symbol
        if(b)
           ^
  symbol:   variable b
  location: class Main
1 error
Language: Java

import java.util.Scanner;

public class Aim {

	public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int i;
        int j = 0, e = 0;
        String s = sc.next();
        s = s.concat(s);
        String p = sc.next();
        if(s.contains(p))System.out.println("Yes");
        else System.out.println("No");
        sc.close();
    }
}


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

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public classMain {
	    public static void main(String[] args)throws IOException {
	        BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
	        String sln;
	        String pln;
	        String ans="No";
	        int plen,j;
	        sln=br.readLine();
	        pln=br.readLine();
	        plen=pln.length();
	        char s[]=(sln+sln.substring(0,plen-1)).toCharArray();
	        char p[]=pln.toCharArray();
	         
	        for(int i=0;i<=s.length-plen;i++){
	            if((s[i]==p[0])&&(s[i+plen-1]==p[plen-1])){
	                    if(plen==1){
	                    	ans="Yes" ;
	                    	break;
	                    }
	            		for(j=1;j<plen-1;j++){
	                        if(s[i+j]==p[j]){
	                            continue;
	                        }else break;
	                 
	                    }
	                    if(j==plen-1) ans="Yes";
	            }
	        }
	        System.out.println(ans);
	    }
	}

Compiler output:
Main.java:5: error: class, interface, enum, or record expected
public classMain {
       ^
Main.java:6: error: unnamed classes are a preview feature and are disabled by default.
	    public static void main(String[] args)throws IOException {
	                  ^
  (use --enable-preview to enable unnamed classes)
Main.java:35: error: class, interface, enum, or record expected
	}
	^
3 errors
Language: Java

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public Main {
	    public static void main(String[] args)throws IOException {
	        BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
	        String sln;
	        String pln;
	        String ans="No";
	        int plen,j;
	        sln=br.readLine();
	        pln=br.readLine();
	        plen=pln.length();
	        char s[]=(sln+sln.substring(0,plen-1)).toCharArray();
	        char p[]=pln.toCharArray();
	         
	        for(int i=0;i<=s.length-plen;i++){
	            if((s[i]==p[0])&&(s[i+plen-1]==p[plen-1])){
	                    if(plen==1){
	                    	ans="Yes" ;
	                    	break;
	                    }
	            		for(j=1;j<plen-1;j++){
	                        if(s[i+j]==p[j]){
	                            continue;
	                        }else break;
	                 
	                    }
	                    if(j==plen-1) ans="Yes";
	            }
	        }
	        System.out.println(ans);
	    }
	}

Compiler output:
Main.java:5: error: class, interface, enum, or record expected
public Main {
       ^
Main.java:6: error: unnamed classes are a preview feature and are disabled by default.
	    public static void main(String[] args)throws IOException {
	                  ^
  (use --enable-preview to enable unnamed classes)
Main.java:35: error: class, interface, enum, or record expected
	}
	^
3 errors
Language: Java

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public Main{
	    public static void main(String[] args)throws IOException {
	        BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
	        String sln;
	        String pln;
	        String ans="No";
	        int plen,j;
	        sln=br.readLine();
	        pln=br.readLine();
	        plen=pln.length();
	        char s[]=(sln+sln.substring(0,plen-1)).toCharArray();
	        char p[]=pln.toCharArray();
	         
	        for(int i=0;i<=s.length-plen;i++){
	            if((s[i]==p[0])&&(s[i+plen-1]==p[plen-1])){
	                    if(plen==1){
	                    	ans="Yes" ;
	                    	break;
	                    }
	            		for(j=1;j<plen-1;j++){
	                        if(s[i+j]==p[j]){
	                            continue;
	                        }else break;
	                 
	                    }
	                    if(j==plen-1) ans="Yes";
	            }
	        }
	        System.out.println(ans);
	    }
}

Compiler output:
Main.java:5: error: class, interface, enum, or record expected
public Main{
       ^
Main.java:6: error: unnamed classes are a preview feature and are disabled by default.
	    public static void main(String[] args)throws IOException {
	                  ^
  (use --enable-preview to enable unnamed classes)
Main.java:35: error: class, interface, enum, or record expected
}
^
3 errors
Language: Java

package Character;

import java.util.Scanner;

public class D{
	public static void main(String[] args){
		Scanner scan = new Scanner(System.in);
		String s = scan.nextLine();
		String p = scan.nextLine();
		if(ringJad(s, p)){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		}
	}

	static boolean ringJad(String s, String p){
		Boolean jad = true;
		//StringBuilder sb = new StringBuilder(s);
		while(true){
			if(s.length() >= p.length()){
				s = s+s;
				break;
			}
			s = s+s;
		}
		System.out.println(s);
		if(!(s.indexOf(p) >= 0)){
			jad = false;
		}
		return jad;


	}

}

Compiler output:
Main.java:5: error: class D is public, should be declared in a file named D.java
public class D{
       ^
1 error
Language: Java

package Character;

import java.util.Scanner;

public class main{
	public static void main(String[] args){
		Scanner scan = new Scanner(System.in);
		String s = scan.nextLine();
		String p = scan.nextLine();
		if(ringJad(s, p)){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		}
	}

	static boolean ringJad(String s, String p){
		Boolean jad = true;
		s = s+s+s;
		System.out.println(s);
		if(!(s.indexOf(p) >= 0)){
			jad = false;
		}
		return jad;


	}

}

Compiler output:
Main.java:5: error: class main is public, should be declared in a file named main.java
public class main{
       ^
1 error
Language: Java

package Character;

import java.util.Scanner;

public class Main{
	public static void main(String[] args){
		Scanner scan = new Scanner(System.in);
		String s = scan.nextLine();
		String p = scan.nextLine();
		if(ringJad(s, p)){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		}
	}

	/**
	 * ringJad
	 * ?????????s???????????????p???????????????????????????
	 * @param s
	 * @param p
	 * @return 
	 */
	static boolean ringJad(String s, String p){
		Boolean jad = true;
		while(true){
			if(s.length() <= p.length()) s += s; break;
		}
	?????????s += s;
		if(!(s.indexOf(p) >= 0)){
			jad = false;
		}
		return jad;
	}

}

Compiler output:
Main.java:29: error: illegal start of expression
	?????????s += s;
	^
Main.java:29: error: illegal start of expression
	?????????s += s;
	 ^
Main.java:29: error: illegal start of expression
	?????????s += s;
	  ^
Main.java:29: error: illegal start of expression
	?????????s += s;
	   ^
Main.java:29: error: illegal start of expression
	?????????s += s;
	    ^
Main.java:29: error: illegal start of expression
	?????????s += s;
	     ^
Main.java:29: error: illegal start of expression
	?????????s += s;
	      ^
Main.java:29: error: illegal start of expression
	?????????s += s;
	       ^
Main.java:29: error: illegal start of expression
	?????????s += s;
	        ^
Main.java:29: error: : expected
	?????????s += s;
	               ^
10 errors
Language: Java

package Character;

import java.util.Scanner;

public class D{
	public static void main(String[] args){
		Scanner scan = new Scanner(System.in);
		String s = scan.nextLine();
		String p = scan.nextLine();
		if(ringJad(s, p)){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		}
	}

	/**
	 * ringJad
	 * ?????????s???????????????p???????????????????????????
	 * @param s
	 * @param p
	 * @return 
	 */
	static boolean ringJad(String s, String p){
		Boolean jad = true;
		while(true){
			if(s.length() <= p.length()) s += s; break;
		}
		
		if(!(s.indexOf(p) >= 0)){
			jad = false;
		}
		return jad;
	}

}

Compiler output:
Main.java:5: error: class D is public, should be declared in a file named D.java
public class D{
       ^
1 error
Language: Java

import java.util.Scanner;
public class Ring {
    public static void main (String[] args) {
	Scanner scan = new Scanner(System.in);
	String s = scan.nextLine();
	String p = scan.nextLine();
	if (match(s, p)) {
	    System.out.println("Yes");
	} else {
	    System.out.println("No");
	}
    }
    public static boolean match (String s, String p) {
	int pLength = p.length();
	String doubleS = s + s;
	for (int i = 0; i < s.length(); i++) {
	    String word = doubleS.substring(i, i+pLength);
	    if (word.equals(p)) {
		return true;
	    }
	}
	return false;
    }
}

Compiler output:
Main.java:2: error: class Ring is public, should be declared in a file named Ring.java
public class Ring {
       ^
1 error
Language: Java

public class ITP1_8_D {
    public static void main(String[] args) {

         java.util.Scanner sc = new java.util.Scanner(System.in);
        String s = sc.next();
        String p = sc.next();
         boolean tf = false;
        String x = "";
        for (int i = 0; i < s.length(); i ++) {
            x = "";
            for (int j = 0; j < p.length(); j ++) { x += s.charAt((i + j) % s.length()); }
            if (x.equals(p)) {
                System.out.println("Yes");
                tf = true;
                break;
            }
        }
        if (tf == false) { System.out.println("No"); }
    }
}

Compiler output:
Main.java:1: error: class ITP1_8_D is public, should be declared in a file named ITP1_8_D.java
public class ITP1_8_D {
       ^
1 error
Language: Java

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.regex.Matcher;
import java.util.regex.Pattern;



public class test{
	public static void main(String[] args){

		BufferedReader reader=new BufferedReader(new InputStreamReader(System.in));

		try{
		String s=reader.readLine();
		String p=reader.readLine();
		String ss=s+s;//s????????????????????¨??§???????????°???1?????¨???????????????

		//??£?????¨???????????£????±??????????

		Pattern pat=Pattern.compile(p);

		check(pat, ss);


		}catch(IOException e){
			System.out.print(e);
		}
	}

	private static void check(Pattern pat, String ss){
		Matcher m=pat.matcher(ss);
		if(m.find()){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		}
	}

}

Compiler output:
Main.java:9: error: class test is public, should be declared in a file named test.java
public class test{
       ^
1 error
Language: Java

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Kadai8_4 {
	public static void main(String[] args)throws IOException{
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String str = br.readLine();
		String result = br.readLine();

		if(str.indexOf(result) != -1){
			System.out.println("Yes.");
		}else{
			System.out.println("No.");
		}
	}
}

Compiler output:
Main.java:5: error: class Kadai8_4 is public, should be declared in a file named Kadai8_4.java
public class Kadai8_4 {
       ^
1 error
Language: Java

import java.util.*;

public class Main{
	public static void main(String[] args){

		Scanner scan = new Scanner(System.in);
		String first = scan.nextLine();
		String fRep = first + first;
		String second = scan.nextLine();
		boolean flg = false;

		for(int i = 0; i < fRep.length(); i++){
			Sting subF = fRep.substring(i, i + second.length());
			if(subF.equals(second)){
				flg = true;
				break;
			}
		}
		System.out.println((flg)? "Yes" : "No");
	}
}

Compiler output:
Main.java:13: error: cannot find symbol
			Sting subF = fRep.substring(i, i + second.length());
			^
  symbol:   class Sting
  location: class Main
1 error
Language: Java

import java.util.*;

public class Main{
	private static final Scanner scan = new Scanner(System.in);

	public static void main(String[] args){
		String s = scan.next();
		String ss = s + s;
		String p = scan.next();
		boolean flag = false;
		for(int i = 0; i < ss.length(); i++){
			String div = ss.substrig(i,i + p.length());
			if(div.equals(p)){
				flag = true;
			}
		}
		System.out.println(flag? "Yes" : "No");
	}
}

Compiler output:
Main.java:12: error: cannot find symbol
			String div = ss.substrig(i,i + p.length());
			               ^
  symbol:   method substrig(int,int)
  location: variable ss of type String
1 error
Language: Java

import java.util.Scanner;

public class Main{
	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);
		String str1 = sc.nextLine();
		String str2 = sc.nextLine();
		
		String str3 = str1 + str1;
		
		if(str3.contains(str2)){
			System.out.println("YES");
		} else {
			System.out.println("No");
		}
	}
}

Compiler output:
Main.java:4: error: cannot find symbol
	public static void main(String[] args) throws IOException {
	                                              ^
  symbol:   class IOException
  location: class Main
1 error
Language: Java

import java.io.*;
import java.util.*;

class Ring{
	String str1;l
	
	Ring(String str1){
		this.str1 = str1 + str1;
	}
}

class Keyword{
	String str2;
	
	Keyword(String str2){
		this.str2 = str2;
	}
}

public class Main{
	public static void main(String[] args) throws IOException{
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		Ring x = new Ring(br.readLine());
		Keyword y = new Keyword(br.readLine());
		
		if(x.str1.contains(y.str2)){
			Sstem.out.println("Yes");
		}else{
			System.out.println("No");
		}
	}
}

Compiler output:
Main.java:5: error: cannot find symbol
	String str1;l
	            ^
  symbol:   class l
  location: class Ring
Main.java:23: error: constructor Ring in class Ring cannot be applied to given types;
		Ring x = new Ring(br.readLine());
		         ^
  required: no arguments
  found:    String
  reason: actual and formal argument lists differ in length
Main.java:27: error: package Sstem does not exist
			Sstem.out.println("Yes");
			     ^
3 errors
Language: Java

package test8;

import java.util.Scanner;

public class Main8D {
	public static void main(String[]args){
		// ????????£?????????????????????
		Scanner sc = new Scanner(System.in);
		// ??±???????????? s
		String s = sc.nextLine();
		//??±???????????? ???
		String p = sc.nextLine();
		//
	
		if(s.indexOf(p) != -1){
			//????????°?????§??????
			System.out.println("Yes");
		}else{
			//????????°?????§?????????
			System.out.println("No");
		}
	}
}

Compiler output:
Main.java:5: error: class Main8D is public, should be declared in a file named Main8D.java
public class Main8D {
       ^
1 error
Language: Java

package test8;

import java.util.Scanner;

public class Main8D {
	public static void main(String[]args){
		// ????????£?????????????????????
		Scanner sc = new Scanner(System.in);
		// ??±???????????? s
		String s = sc.nextLine();
		//??±???????????? ???
		String p = sc.nextLine();
		//
		
		if(s.indexOf(p) != -1){
			//????????°?????§??????
			System.out.println("Yes");
		}else{
			//????????°?????§?????????
			System.out.println("No");
		}
	}
}

Compiler output:
Main.java:5: error: class Main8D is public, should be declared in a file named Main8D.java
public class Main8D {
       ^
1 error
Language: Java

import java.util.Scanner;

public class Ring {
	private static Scanner sc=new Scanner(System.in);
	private static String s=sc.nextLine();
	private static String p=sc.nextLine();
	private static String str=s+s;
	private static boolean possible=false;
	public static void main(String[] args){
		for(int i=0;i<s.length();i++){
			String word=str.substring(i,i+p.length());
			if(word.equals(p)){
				possible=true;
			}
		}
		if(possible) System.out.println("Yes");
		else System.out.println("No");
	}
}

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

package sample;

//import java.util.Scanner;
//import java.io.*;

 class Main {
    public static void main(String[] args){ 
    	InputStreamReader in = new InputStreamReader(System.in);
        BufferedReader reader = new BufferedReader(in);
    	   	                                                 
    	String s = reader.readerLine();
        String p = reader.readerLine();        
        2s = s + p;

        if(2s.indexOf(p) != -1){
        System.out.println("Yes")
        }      
        else{
        System.out.println("No");
        }
    }
}

Compiler output:
Main.java:13: error: not a statement
        2s = s + p;
        ^
Main.java:13: error: ';' expected
        2s = s + p;
         ^
Main.java:15: error: ')' expected
        if(2s.indexOf(p) != -1){
            ^
Main.java:15: error: not a statement
        if(2s.indexOf(p) != -1){
                         ^
Main.java:15: error: ';' expected
        if(2s.indexOf(p) != -1){
                              ^
Main.java:16: error: ';' expected
        System.out.println("Yes")
                                 ^
Main.java:18: error: 'else' without 'if'
        else{
        ^
7 errors
Language: Java

public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String s = br.readLine();
		String p = br.readLine();
		int sLen = s.length();
		int pLen = p.length();

		boolean foundP = false;

		for(int i = 0; i < sLen; i++) {

			for(int j = 0; j < pLen; j++) {
				int k = (i + j) % sLen;
				char sc = s.charAt(k);
				char pc = p.charAt(j);

				if(sc != pc) {
					break;
				}

				if(j == pLen-1) {
					foundP = true;
					break;
				}
			}

			if(foundP) {
				break;
			}
		}

		if(foundP) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

		br.close();
	}
}

Compiler output:
Main.java:2: error: cannot find symbol
	public static void main(String[] args) throws IOException {
	                                              ^
  symbol:   class IOException
  location: class Main
Main.java:3: error: cannot find symbol
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		^
  symbol:   class BufferedReader
  location: class Main
Main.java:3: error: cannot find symbol
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		                        ^
  symbol:   class BufferedReader
  location: class Main
Main.java:3: error: cannot find symbol
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		                                           ^
  symbol:   class InputStreamReader
  location: class Main
4 errors
Language: Java

import java.util.*;

public class Main{
    public static void main(String[] args)throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String str1;
        String str2;
        
        str1 = br.readLine();
        str1 += str1;

        str2 = br.readLine();
        
        if(str1.indexOf(str2) == -1){
            System.out.println("NO");
        }else{
            System.out.println("YES");
        }
        
    }
}

Compiler output:
Main.java:4: error: cannot find symbol
    public static void main(String[] args)throws IOException{
                                                 ^
  symbol:   class IOException
  location: class Main
Main.java:5: error: cannot find symbol
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        ^
  symbol:   class BufferedReader
  location: class Main
Main.java:5: error: cannot find symbol
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
                                ^
  symbol:   class BufferedReader
  location: class Main
Main.java:5: error: cannot find symbol
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
                                                   ^
  symbol:   class InputStreamReader
  location: class Main
4 errors
Language: Java

import java.util.*;

class Main{
	public static void main(String[] args){
		
		int top=0;
		boolean flag = false;
		
		Scanner sc = new Scanner(System.in);
		String s1 = sc.nextLine();
		String s = s1+s1;
		String p = sc.nextLine();		
		for(int i=0;i<s.length();i++){
			if(p.equals(s.substring(top,top+p.length()))){
				flag = true;
				break;
			}
			top++;
		}
		if(flag){
			System.out.println("Yes")
		}else{
			System.out.println("No");
		}
	}
}

Compiler output:
Main.java:21: error: ';' expected
			System.out.println("Yes")
			                         ^
1 error
Language: Java

public class Main {
     
    public void run(java.io.InputStream in, java.io.PrintStream out) {
        final java.util.Scanner sc = new java.util.Scanner(in);
        String s, p;
         
        s = sc.next();
        p = sc.next();
         
        if ((s + s).contains(p)) {
            out.println("Yes");
        } else {
            out.println("No");
        }
    }
 
    public static void main(String[] args) {
        (new Main()).run(System.in, System.out);
    }
 


Compiler output:
Main.java:19: error: reached end of file while parsing
    }
     ^
1 error
Language: Java

import java.util.Scanner;

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

        String s = sc.next();
        String p = sc.next();

        int j;

        for(int i = 0; i < s.length(); i++){
            if(s.charAt(i) == p.charAt(0)){
                int a = i;
                j = 0;
                while(true){
                    if(j == p.length())
                        break;
                    if(a + j == s.length())
                        a = -j
                    if(s.charAt(a + j) != p.charAt(j))
                        break;
                }
                if(j == p.length())
                    break;
                else
                    j = 0;
            }
        }
        if(j == p.length())
            System.out.println("Yes");
        else
            System.out.println("No");

        sc.close();
    }
}



Compiler output:
Main.java:20: error: ';' expected
                        a = -j
                              ^
1 error
Language: Java

import java.util.*;

public class Ex22{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    char cp,sp;
    int bi=0,i,pi,si;
    String s = sc.nextLine();
    String p = sc.nextLine();
    for(pi = 0;pi < p.length();pi++){
      cp = p.charAt(pi);
      for(si = 0;si < s.length();si++){
        i = (bi+si) % s.length();
        sp = s.charAt(i);
        if(cp == sp){
          bi = i;
          break;
        }
      }
      if(si == s.length()){
        System.out.println("No");
        break;
      }
    }
    if(pi == p.length())System.out.println("Yes");
    sc.close();
  }
}



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

import java.util.Scanner;
public class s9{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String str = sc.nextLine();
        String key = sc.nextLine();
        String test = str+str;

        if(test.contains(key)) {
        	System.out.println("Yse");
        }else {
        	System.out.println("No");
        }
        sc.close();
    }
}


Compiler output:
Main.java:2: error: class s9 is public, should be declared in a file named s9.java
public class s9{
       ^
1 error
Language: Java

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
 
public class Main {
 
    public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
        String s1 = new String(sc.nextLine());
        String s2 = new String(s1+s1);
        String s3 = new String(sc.nextLine());
        
        if(s2.indexOf(s3) != -1){
        	System.out.println("Yes");
        }
        else{
        	System.out.println("No");
        }
        sc.close();
    }
 
}


Compiler output:
Main.java:8: error: cannot find symbol
		Scanner sc = new Scanner(System.in);
		^
  symbol:   class Scanner
  location: class Main
Main.java:8: error: cannot find symbol
		Scanner sc = new Scanner(System.in);
		                 ^
  symbol:   class Scanner
  location: class Main
2 errors
Language: Java

import java.io.*;
public class Ring {
	public static boolean search(String str,String key){
		int cursol = 0;
		int flag=0;
		for(int i = 0 ;; i ++){
			if(cursol!=0 && str.charAt(i)!=key.charAt(cursol))
				cursol=0;
			if(str.charAt(i)==key.charAt(cursol)){
				cursol++;
			}
			if(cursol==key.length()){
				return true;
			}
			if(i==str.length()-1){
				i=-1;
				flag++;
			}
			if(flag==2){
				return false;
			}
		}
	}
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String str = br.readLine();
		String key = br.readLine();
		if(str.indexOf(key)!=-1)
			System.out.println("Yes");
		else{
			if(search(str,key))
				System.out.println("Yes");
			else
				System.out.println("No");
		}
	}
}

Compiler output:
Main.java:2: error: class Ring is public, should be declared in a file named Ring.java
public class Ring {
       ^
1 error
Language: Java

import java.io.*;
public class Main{
	public static boolean search(String str,String key){
		int cursol = 0;
		int flag=0;
		for(int i = 0 ;; i ++){
			if(cursol!=0 && str.charAt(i)!=key.charAt(cursol))
				cursol=0;
			if(str.charAt(i)==key.charAt(cursol)){
				cursol++;
			}
			if(cursol==key.length()){
				return true;
			}
			if(i==str.length()-1){
				if(flag==0){
					i=-1;
				flag++;
			}
			if(flag==2){
				return false;
			}
		}
	}
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String str = br.readLine();
		String key = br.readLine();
		if(str.indexOf(key)!=-1)
			System.out.println("Yes");
		else{
			if(search(str,key))
				System.out.println("Yes");
			else
				System.out.println("No");
		}
	}
}

Compiler output:
Main.java:25: error: illegal start of expression
	public static void main(String[] args) throws IOException {
	^
1 error
Language: C

#include <stdio.h>
#include <string.h>
int main() {
	char str1[101], str2[101];
	int i, j;
	gets(str1);
	gets(str2);
	if (strstr(str1, str2)!=NULL)
		printf("yes");
	else
		printf("No");
}


Compiler output:
main.c: In function 'main':
main.c:6:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    6 |         gets(str1);
      |         ^~~~
      |         fgets
Language: C

#include <stdio.h>
#include <string.h>
int main() {
	char s,str1[101], str2[101];
	int i=0, j=0;
	scanf_s("%s", str1);
	scanf_s("%s", str2);
	strcpy(str1, str2);
	strcat(str1, str2);
	if (strstr(str1, str2)==NULL)
		printf("No");
	else
		printf("Yes");
}


Compiler output:
main.c: In function 'main':
main.c:6:9: error: implicit declaration of function 'scanf_s'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    6 |         scanf_s("%s", str1);
      |         ^~~~~~~
      |         scanf
Language: C

#include<stdio.h>
int main()
{
 char str1[100],str2[100];

 scanf("%c%c",str1,str2);

 char a[] strcat(str1,str1);
 
 if(strstr(a,str2))printf("Yes\n");
 else printf("No");

 return 0;

}



Compiler output:
main.c: In function 'main':
main.c:8:11: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'strcat'
    8 |  char a[] strcat(str1,str1);
      |           ^~~~~~
main.c:8:11: error: implicit declaration of function 'strcat' [-Wimplicit-function-declaration]
main.c:2:1: note: include '<string.h>' or provide a declaration of 'strcat'
    1 | #include<stdio.h>
  +++ |+#include <string.h>
    2 | int main()
main.c:8:11: warning: incompatible implicit declaration of built-in function 'strcat' [-Wbuiltin-declaration-mismatch]
    8 |  char a[] strcat(str1,str1);
      |           ^~~~~~
main.c:8:11: note: include '<string.h>' or provide a declaration of 'strcat'
main.c:10:5: error: implicit declaration of function 'strstr' [-Wimplicit-function-declaration]
   10 |  if(strstr(a,str2))printf("Yes\n");
      |     ^~~~~~
main.c:10:5: note: include '<string.h>' or provide a declaration of 'strstr'
main.c:10:5: warning: incompatible implicit declaration of built-in function 'strstr' [-Wbuiltin-declaration-mismatch]
main.c:10:5: note: include '<string.h>' or provide a declaration of 'strstr'
main.c:10:12: error: 'a' undeclared (first use in this function)
   10 |  if(strstr(a,str2))printf("Yes\n");
      |            ^
main.c:10:12: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>


char *gets(char *s);

int main()
{
	char s[210], p[110];
	char *pp;
	int i, len1, len2;


	gets(s);
	len1 = strlen(s);
	strcpy(p, s);
	strcpy(s + len1, p);

	gets(p);
	len2 = strlen(p);

	for (i = 0, pp = s; ; i++, pp++) {
		if (i >= len1) {
			puts("No");
			break;
		}
		if (!strncmp(pp, p, len2)) {
			puts("Yes");
			break;
		}
	}
	return 0;
}



Compiler output:
main.c: In function 'main':
main.c:14:16: error: implicit declaration of function 'strlen' [-Wimplicit-function-declaration]
   14 |         len1 = strlen(s);
      |                ^~~~~~
main.c:2:1: note: include '<string.h>' or provide a declaration of 'strlen'
    1 | #include <stdio.h>
  +++ |+#include <string.h>
    2 | 
main.c:14:16: warning: incompatible implicit declaration of built-in function 'strlen' [-Wbuiltin-declaration-mismatch]
   14 |         len1 = strlen(s);
      |                ^~~~~~
main.c:14:16: note: include '<string.h>' or provide a declaration of 'strlen'
main.c:15:9: error: implicit declaration of function 'strcpy' [-Wimplicit-function-declaration]
   15 |         strcpy(p, s);
      |         ^~~~~~
main.c:15:9: note: include '<string.h>' or provide a declaration of 'strcpy'
main.c:15:9: warning: incompatible implicit declaration of built-in function 'strcpy' [-Wbuiltin-declaration-mismatch]
main.c:15:9: note: include '<string.h>' or provide a declaration of 'strcpy'
main.c:26:22: error: implicit declaration of function 'strncmp' [-Wimplicit-function-declaration]
   26 |                 if (!strncmp(pp, p, len2)) {
      |                      ^~~~~~~
main.c:26:22: note: include '<string.h>' or provide a declaration of 'strncmp'
main.c:26:37: warning: 'strncmp' argument 3 type is 'int' where 'long unsigned int' is expected in a call to built-in function declared without prototype [-Wbuiltin-declaration-mismatch]
   26 |                 if (!strncmp(pp, p, len2)) {
      |                                     ^~~~
<built-in>: note: built-in 'strncmp' declared here
Language: C

#include <iostream>
using namespace std;

int main() {
    string s,p,ans="No";
    cin >> s >> p;
    int i,j,ss=s.size(),ps=p.size();
    for (i=0;i<ss;i++) {
        for (j=0;j<ps;j++) {
            if (s[(i+j)%ss] != p[j]) break;
        }
        if (j>=ps) {
            ans="Yes";
            break;
        }
    }
    cout << ans << endl;
    return 0;
}


Compiler output:
main.c:1:10: fatal error: iostream: No such file or directory
    1 | #include <iostream>
      |          ^~~~~~~~~~
compilation terminated.
Language: C


#include <stdio.h>


char *gets(char *s);

int main()
{
	char s[210], p[110];
	char *pp;
	int i, len1, len2;


	gets(s);
	len1 = strlen(s);
	strcpy(p, s);
	strcpy(s + len1, p);

	gets(p);
	len2 = strlen(p);

	for (i = 0, pp = s; ; i++, pp++) {
		if (i >= len1) {
			puts("No");
			break;
		}
		if (!strncmp(pp, p, len2)) {
			puts("Yes");
			break;
		}
	}
	return 0;
}






Compiler output:
main.c: In function 'main':
main.c:15:16: error: implicit declaration of function 'strlen' [-Wimplicit-function-declaration]
   15 |         len1 = strlen(s);
      |                ^~~~~~
main.c:3:1: note: include '<string.h>' or provide a declaration of 'strlen'
    2 | #include <stdio.h>
  +++ |+#include <string.h>
    3 | 
main.c:15:16: warning: incompatible implicit declaration of built-in function 'strlen' [-Wbuiltin-declaration-mismatch]
   15 |         len1 = strlen(s);
      |                ^~~~~~
main.c:15:16: note: include '<string.h>' or provide a declaration of 'strlen'
main.c:16:9: error: implicit declaration of function 'strcpy' [-Wimplicit-function-declaration]
   16 |         strcpy(p, s);
      |         ^~~~~~
main.c:16:9: note: include '<string.h>' or provide a declaration of 'strcpy'
main.c:16:9: warning: incompatible implicit declaration of built-in function 'strcpy' [-Wbuiltin-declaration-mismatch]
main.c:16:9: note: include '<string.h>' or provide a declaration of 'strcpy'
main.c:27:22: error: implicit declaration of function 'strncmp' [-Wimplicit-function-declaration]
   27 |                 if (!strncmp(pp, p, len2)) {
      |                      ^~~~~~~
main.c:27:22: note: include '<string.h>' or provide a declaration of 'strncmp'
main.c:27:37: warning: 'strncmp' argument 3 type is 'int' where 'long unsigned int' is expected in a call to built-in function declared without prototype [-Wbuiltin-declaration-mismatch]
   27 |                 if (!strncmp(pp, p, len2)) {
      |                                     ^~~~
<built-in>: note: built-in 'strncmp' declared here
Language: C

#include <iostream>
using namespace std;

int main() 
{
    string s,p,ans="No";
    cin >> s >> p;
    int i,j,ss=s.size(),ps=p.size();
    for (i=0;i<ss;i++) {
        for (j=0;j<ps;j++) {
            if (s[(i+j)%ss] != p[j]) break;
        }
        if (j>=ps)
 {
            ans="Yes";
            break;
        }
    }
    cout << ans << endl;
    return 0;
}


Compiler output:
main.c:1:10: fatal error: iostream: No such file or directory
    1 | #include <iostream>
      |          ^~~~~~~~~~
compilation terminated.
Language: C

#include <stdio.h>

char *gets(char *s);

int main()
{
	char s[210], p[110];
	char *pp;
	int i, len1, len2;


	gets(s);
	len1 = strlen(s);
	strcpy(p, s);
	strcpy(s + len1, p);

	gets(p);
	len2 = strlen(p);

	for (i = 0, pp = s; ; i++, pp++) {
		if (i >= len1) {
			puts("No");
			break;
		}
		if (!strncmp(pp, p, len2)) {
			puts("Yes");
			break;
		}
	}
	return 0;
}



Compiler output:
main.c: In function 'main':
main.c:13:16: error: implicit declaration of function 'strlen' [-Wimplicit-function-declaration]
   13 |         len1 = strlen(s);
      |                ^~~~~~
main.c:2:1: note: include '<string.h>' or provide a declaration of 'strlen'
    1 | #include <stdio.h>
  +++ |+#include <string.h>
    2 | 
main.c:13:16: warning: incompatible implicit declaration of built-in function 'strlen' [-Wbuiltin-declaration-mismatch]
   13 |         len1 = strlen(s);
      |                ^~~~~~
main.c:13:16: note: include '<string.h>' or provide a declaration of 'strlen'
main.c:14:9: error: implicit declaration of function 'strcpy' [-Wimplicit-function-declaration]
   14 |         strcpy(p, s);
      |         ^~~~~~
main.c:14:9: note: include '<string.h>' or provide a declaration of 'strcpy'
main.c:14:9: warning: incompatible implicit declaration of built-in function 'strcpy' [-Wbuiltin-declaration-mismatch]
main.c:14:9: note: include '<string.h>' or provide a declaration of 'strcpy'
main.c:25:22: error: implicit declaration of function 'strncmp' [-Wimplicit-function-declaration]
   25 |                 if (!strncmp(pp, p, len2)) {
      |                      ^~~~~~~
main.c:25:22: note: include '<string.h>' or provide a declaration of 'strncmp'
main.c:25:37: warning: 'strncmp' argument 3 type is 'int' where 'long unsigned int' is expected in a call to built-in function declared without prototype [-Wbuiltin-declaration-mismatch]
   25 |                 if (!strncmp(pp, p, len2)) {
      |                                     ^~~~
<built-in>: note: built-in 'strncmp' declared here
Language: C

#include <iostream> 
 #include <string> 
 using namespace std; 
 
 
 int main() 
 { 
     string s, p; 
     bool res = false; 
 
 
     getline(cin, s); 
     getline(cin, p); 
 
 
     for (int i = 0; i < s.size(); i++) 
         if (s[i] == p[0]) { 
             res = true; 
             for (int j = 0; j < p.size(); j++) 
                 if (s[(i + j) % s.size()] != p[j]) { 
                    res = false; 
                    break;  
                 } 
             if (res) 
                 break; 
         } 
 
 
     cout << (res ? "Yes" : "No") << endl; 
 
 
     return 0; 
 } 



Compiler output:
main.c:1:10: fatal error: iostream: No such file or directory
    1 | #include <iostream>
      |          ^~~~~~~~~~
compilation terminated.
Language: C

#include <stdio.h>
#include <string.h>

 char t1[1510];
 char t2[1510];

 int main(void)
 {
	int i,j;
	int n1,n2;
	int ok=0;

	gets(t1);
	gets(t2);

	n1=strlen(t1);
	n2=strlen(t2);

	for(i=0;i<n1;i++){
		t1[i+n1]=t1[i];
	}
	n1*=2;
	for(i=0;i<n1-n2+1;i++){
		for(j=0;j<n2;j++){
			if(t1[i+j]!=t2[j]) break;
			if(j==n2-1) ok=1;
		}
	}

if(ok) puts("Yes");
else puts("No");
return 0;

}



Compiler output:
main.c: In function 'main':
main.c:13:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
   13 |         gets(t1);
      |         ^~~~
      |         fgets
Language: C

#include <stdio.h>
#include <string.h>

 char t1[1510];
 char t2[1510];

 int main()
 {
	int i,j;
	int n1,n2;
	int ok=0;

	gets(t1);
	gets(t2);

	n1=strlen(t1);
	n2=strlen(t2);

	for(i=0;i<n1;i++){
		t1[i+n1]=t1[i];
	}
	n1*=2;
	for(i=0;i<n1-n2+1;i++){
		for(j=0;j<n2;j++){
			if(t1[i+j]!=t2[j]) break;
			if(j==n2-1) ok=1;
		}
	}

if(ok) puts("Yes");
else puts("No");
return 0;

}



Compiler output:
main.c: In function 'main':
main.c:13:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
   13 |         gets(t1);
      |         ^~~~
      |         fgets
Language: C

#include <stdio.h>
#include <string.h>

char t1[1510];
char t2[1510];

int main(void)
{
	int i,j;
	int n1,n2;
	int ok=0;
	gets(t1);
	gets(t2);

	n1=strlen(t1);
	n2=strlen(t2);

	for(i=0;i<n1;i++){
		t1[i+n1]=t1[i];
	}
	n1*=2;
	for(i=0;i<n1-n2+1;i++){
		for(j=0;j<n2;j++){
			if(t1[i+j]!=t2[j]) break;
			if(j==n2-1) ok=1;
		}
	}
	if(ok) puts("Yes");
	else puts("No");
return 0;
}


Compiler output:
main.c: In function 'main':
main.c:12:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
   12 |         gets(t1);
      |         ^~~~
      |         fgets
Language: C

#include <stdio.h>
#include <string.h>
char t1[1510];
char t2[1510];
int main(void){
	int i,j;
	int n1,n2;
	int ok=0;
	gets(t1);
	gets(t2);
	n1=strlen(t1);
	n2=strlen(t2);
	for(i=0;i<n1;i++){
		t1[i+n1]=t1[i];
	}
	n1*=2;
	for(i=0;i<n1-n2+1;i++){
		for(j=0;j<n2;j++){
			if(t1[i+j]!=t2[j]) break;
			if(j==n2-1) ok=1;
		}
	}
	if(ok) puts("Yes");
	else puts("No");
	return 0;
}



Compiler output:
main.c: In function 'main':
main.c:9:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    9 |         gets(t1);
      |         ^~~~
      |         fgets
Language: C

#include <stdio.h>
#include <string.h>
 char t1[1510];
 char t2[1510];
int main(void){
	int i,j;
	int n1,n2;
	int ok=0;
	gets(t1);
	gets(t2);
	n1=strlen(t1);
	n2=strlen(t2);
	for(i=0;i<n1;i++){
		t1[i+n1]=t1[i];
	}
	n1*=2;
	for(i=0;i<n1-n2+1;i++){
		for(j=0;j<n2;j++){
			if(t1[i+j]!=t2[j]) break;
			if(j==n2-1) ok=1;
		}
	}
	if(ok) puts("Yes");
	else puts("No");
	return 0;
}



Compiler output:
main.c: In function 'main':
main.c:9:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    9 |         gets(t1);
      |         ^~~~
      |         fgets