criyle/codenet-compile-errors huggingface dataset:
Language: Java

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

public class B112{
  public static void main(String[] args){
    Scanner scan = new Scanner(System.in);
    int N = scan.nextInt();
    int T = scan.nextInt();
    int MinCost = 0;
    boolean flag = false;

    int[][] d = new int[N][2];
    for(int i = 0; i < N; i++){
      d[i][0] = scan.nextInt();
      d[i][1] = scan.nextInt();
      if(d[i][1] <= T){
        flag = true;
        MinCost = d[i][0];
      }
    }


    if(flag == false){
      System.out.println("TLE");
    }else{
      for(int i = 0; i < N ; i++){
        if((T >= d[i][1])&&(MinCost > d[i][0]))
          MinCost = d[i][0];
      }
      System.out.println(MinCost);
    }
  }
}


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

#include <iostream>
using namespace std;
 
int main() {
	int N,T;
	int a = 1001;
	cin >> N >> T;
	for(int i = 0; i < N; i++){
		int c,t;
		cin >> c >> t;
		if(t <= T && c < a){
			a = c;
		}
	}
	if(ans == 1001){
		cout << "TLE" << endl;
	} else {
		cout << a << endl;
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:12: error: 'ans' was not declared in this scope; did you mean 'abs'?
   15 |         if(ans == 1001){
      |            ^~~
      |            abs
Language: C++

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

int main(){
  int N,T,A;
  cin >> N >> T; 
  vector<int> cost(N),time(N),ans(0);
  for(int i=0;i < N;i++){
    cin >> cost[i] >> time[i]
  }
  for(int i=0;i < N;i++){
    if(time[i]<T)
      ans.push_back(i);
  }
  for(int i=0;i < ans.size();i++){
    ans[i]=cost[ans[i]];
  }
  sort(ans.begin(),ans.end());
  cout << ans[0] << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:30: error: expected ';' before '}' token
    9 |     cin >> cost[i] >> time[i]
      |                              ^
      |                              ;
   10 |   }
      |   ~
Language: C++

#include <iostream>
using namespace std;

int main(){
  int N,T,c,t;
  int cost=1001
  cin>>N>>T;
  for (int i=0;i<N;i++){
    cin>>c>>t;
    if (t<T && c<cost){
      cost=c;
    }
  }
  if (cost==1001){
    cout<<"TLE"<<endl;
  }
  else{
    cout<<cost<<endl;
  }
}
      
      

Compiler output:
a.cc: In function 'int main()':
a.cc:7:3: error: expected ',' or ';' before 'cin'
    7 |   cin>>N>>T;
      |   ^~~
Language: Java

import java.util.*;

public class Problem2 {
    public static void main(String args[]){
        int N,T;
        int min = 0;
        Scanner scanner = new Scanner(System.in);
        N = scanner.nextInt();
        T = scanner.nextInt();
        for(int i = 1; i <= N; i++){
            int c = scanner.nextInt();
            int t = scanner.nextInt();
            if(t <= T){
                if(min == 0){
                    min = c;
                }else{
                    if(c < min){
                        min = c;
                    }
                }
            }
        }
        System.out.println(min);
    }
}

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

#include <iostream>
using namespace std;
int main() {
   int N,T,c,t;
   cin >> N>>T;
   int a[100];
   for(int i=0;i<100;i++) {
      cin>>a[i].c>>a[i].t
      }
   
   cin >> A >> B;
   cout << A + B << endl;
	}
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:17: error: request for member 'c' in 'a[i]', which is of non-class type 'int'
    8 |       cin>>a[i].c>>a[i].t
      |                 ^
a.cc:8:25: error: request for member 't' in 'a[i]', which is of non-class type 'int'
    8 |       cin>>a[i].c>>a[i].t
      |                         ^
a.cc:11:11: error: 'A' was not declared in this scope
   11 |    cin >> A >> B;
      |           ^
a.cc:11:16: error: 'B' was not declared in this scope
   11 |    cin >> A >> B;
      |                ^
a.cc: At global scope:
a.cc:14:9: error: expected unqualified-id before 'return'
   14 |         return 0;
      |         ^~~~~~
a.cc:15:1: error: expected declaration before '}' token
   15 | }
      | ^
Language: Java

import java.util.*;
import java.lang.*;
import java.io.*;
public class Main{
	public static void main (String[] args){
		Scanner sc = new Scanner (System.in);
		int N = sc.nextInt();
		int T = sc.nextInt();
		 c[] = new int[N];
		 t[] = new int[N];
		int p = 1001;
		for (int i = 0; i < N; i++) {
			c[i] = sc.nextInt();
		}
		for (int i = 0; i < N; i++) {
			t[i] = sc.nextInt();
		}
		for (int i = 0; i < N; i++) {
			if (t[i] <= T && c[i] < p) {
				p = c[i];
			}
		}
		if (p == 1001) {
			System.out.println("TLE");
		} else {
			System.out.println(p);
		}
	}
}

Compiler output:
Main.java:9: error: not a statement
		 c[] = new int[N];
		  ^
Main.java:9: error: ';' expected
		 c[] = new int[N];
		    ^
Main.java:9: error: not a statement
		 c[] = new int[N];
		       ^
Main.java:10: error: not a statement
		 t[] = new int[N];
		  ^
Main.java:10: error: ';' expected
		 t[] = new int[N];
		    ^
Main.java:10: error: not a statement
		 t[] = new int[N];
		       ^
6 errors
Language: Java

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

public class Main{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int T = sc.nextInt();
		int[] c = new int[N];
		int[] t = new int[N];
		int p = 1100;
		for(int i = 0; i < N; i++){
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
		}
		for(int i = 0; i < N; i++){
			if((t[i] <= T) && (c[i] < p)){
					p = c[i];
				}
			}
		}
		if(p == 1100){
			System.out.println("TLE");
		}else{
			System.out.println(p);
		}
	}
}

Compiler output:
Main.java:23: error: illegal start of type
		if(p == 1100){
		^
Main.java:23: error: <identifier> expected
		if(p == 1100){
		    ^
Main.java:25: error: illegal start of type
		}else{
		 ^
Main.java:29: error: class, interface, enum, or record expected
}
^
4 errors
Language: Java

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

public class Main{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int T = sc.nextInt();
		int[] c = new int[N];
		int[] t = new int[N];
		int p = 1100;
		for(int i = 0; i < N; i++){
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
		}
		for(int i = 0; i < N; i++){
			if((t[i] < T) && (c[i] < p){
				p = c[i];
			}
		}
		if(p == 1100){
			System.out.println("TLE");
		}else{
			System.out.println(p);
		}
	}
}

Compiler output:
Main.java:18: error: ')' expected
			if((t[i] < T) && (c[i] < p){
			                           ^
1 error
Language: Java

import java.util.*;
import java.lang.*;
import java.io.*;
public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner (System.in);
		int N = sc.nextInt();
		int T = sc.nextInt();
		int[] c = new int [N];
		int[] t = new int[N];
		int p = 1100;
		for (int i = 0; i < N ; i++) {
			int j = i + 1;
			c[j] = sc.nextInt();
			t[j] = sc.nextInt();
		}
		for (int i = 0; i < N; i++) {
			j = i +1;
			if (t [j] <= T) {
				if (c[j] < p) {
					p = c[j];
				}
			}
		}
		if (p == 1100) {
			System.out.println ("TLE");
		} else {
			System.out.println(p);
		}
	}
}

Compiler output:
Main.java:18: error: cannot find symbol
			j = i +1;
			^
  symbol:   variable j
  location: class Main
Main.java:19: error: cannot find symbol
			if (t [j] <= T) {
			       ^
  symbol:   variable j
  location: class Main
Main.java:20: error: cannot find symbol
				if (c[j] < p) {
				      ^
  symbol:   variable j
  location: class Main
Main.java:21: error: cannot find symbol
					p = c[j];
					      ^
  symbol:   variable j
  location: class Main
4 errors
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
  int n,t,c,b,m=1001;
  cin>>n>>t;
  for(int i=0;i<n;i++){
    cin>>c>>b;
    if(b<=t)
      m=min(c,m);
  }
  cout<<(m==1001?"TLE":m);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:17: error: operands to '?:' have different types 'const char*' and 'int'
   11 |   cout<<(m==1001?"TLE":m);
      |          ~~~~~~~^~~~~~~~
Language: C++

#include <iostream>
#include <algorithm>
using namespace std;
const int INF = 10000000;

int main(){
    int n,T;
    cin >> n >> T;
    int cost[n],timee[n];
    for ( int i = 0;i < n;i++) cin >> cost[i] >> timee[i];

    int ans = INF;

     for ( int i = 0;i < n;i++) {
         if (timee[i] <= T) ans = min(ans,cost[i])
     }
     if (ans == INF) cout << "TLE" << endl;
     else cout << ans << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:51: error: expected ';' before '}' token
   15 |          if (timee[i] <= T) ans = min(ans,cost[i])
      |                                                   ^
      |                                                   ;
   16 |      }
      |      ~
Language: C++

#include <stdio.h>
 
int main()
{
     int N, T, c[1001], t[1001], min;
     scanf("%d %d", &N, &T);
 
     for(i=0;i<N+1;i++){
         scanf("%d %d", &c[i], &t[i]);
     }
 
     for(i=0;i<N+1;i++){
           if(t[i]>T){
                    printf("TLE\n");
           }else{
                    for(i=0;i<N+1;i++){
                             if(c[i]<T)  min=c[i];
                     }
           printf("%d\n", min);
      }
      return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:10: error: 'i' was not declared in this scope
    8 |      for(i=0;i<N+1;i++){
      |          ^
a.cc:12:10: error: 'i' was not declared in this scope
   12 |      for(i=0;i<N+1;i++){
      |          ^
a.cc:22:2: error: expected '}' at end of input
   22 | }
      |  ^
a.cc:4:1: note: to match this '{'
    4 | {
      | ^
Language: C++

#include <iostream>

using namespace std;

int main()
{
	int routeCount, limitTime;
	cin >> routeCount >> limitTime;

	int minimumCost = INT_MAX;
	for (int routeIndex = 0; routeIndex < routeCount; routeIndex++)
	{
		int cost, routeTime;
		cin >> cost >> routeTime;

		if ((routeTime <= limitTime) && (cost < minimumCost))
		{
			minimumCost = cost;
		}
	}

	if (minimumCost > 1000)
	{
		cout << "TLE" << endl;
	}
	else
	{
		cout << minimumCost << endl;
	}

	return 0;
}


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

#include<bits/stdc++.h>
using namespace std;
int main () {
  int N, T;
  cin >> N >> T;
  int cost[N];
  int time[N];
  for (int i = 0; i < N; i ++) {
    cin >> cost[i] >> time[i] ;
    if (time[i] > T) cost[i] = 2000;
  }
  sort (cost. begin(), cost.end());
  if (cost[0] > 1000) cout << "TLE" << endl;
  else cout << cost[0] << endl;
}
  

Compiler output:
a.cc: In function 'int main()':
a.cc:12:15: error: request for member 'begin' in 'cost', which is of non-class type 'int [N]'
   12 |   sort (cost. begin(), cost.end());
      |               ^~~~~
a.cc:12:29: error: request for member 'end' in 'cost', which is of non-class type 'int [N]'
   12 |   sort (cost. begin(), cost.end());
      |                             ^~~
Language: C++

#include <iostream>
#include <memory>

void main()
{
	int N, T;
	std::cin >> N >> T;
	const int MinCostMax = 1000;
	int minCost = MinCostMax + 1;
	for (int i = 0; i < N; i++) {
		int c, t;
		std::cin >> c >> t;
		if (c < minCost && t <= T)
		{
			minCost = c;
		}
	}
	if (minCost > 1000)
	{
		std::cout << "TLE";
		return;
	}
	std::cout << minCost;
}

Compiler output:
a.cc:4:1: error: '::main' must return 'int'
    4 | void main()
      | ^~~~
a.cc: In function 'int main()':
a.cc:21:17: error: return-statement with no value, in function returning 'int' [-fpermissive]
   21 |                 return;
      |                 ^~~~~~
Language: C

#include <stdio.h>
int main(){
    int n=0,t=0,c[2000],time[2000],i=0,min=10000;
    scanf("%d",&n);
    scanf("%d",&t);
    for(i=0;i<n;i++0){
        scanf("%d",&c[i]);
        scanf("%d",&time[i]);
    }

    for(i=0;i<n;i++){
        if(time[i]<=t){
            if(c[i]<min){
                min=c[i];
            }
        }
    }
    
    if(min==10000){
        printf("TLE");
    }else{
        printf("%d",min);
    }

    return 0;
}    

Compiler output:
main.c: In function 'main':
main.c:6:20: error: expected ')' before numeric constant
    6 |     for(i=0;i<n;i++0){
      |        ~           ^
      |                    )
Language: C

#include <stdio.h>
int main(){
    int n=0,t=0,c[2000],time[2000],i=0,min=10000;
    scanf("%d",&n);
    scanf("%d",&t);
    for(i=0;i<n;i++0){
        scanf("%d",&c[i]);
        scanf("%d",&time[i]);
    }

    for(i=0;i<n;i++){
        if(time[i]<=t){
            if(c[i]<min){
                min=c[i]
            }
        }
    }
    
    if(min==10000){
        printf("TLE");
    }else{
        printf("%d",min);
    }

    return 0;
}    

Compiler output:
main.c: In function 'main':
main.c:6:20: error: expected ')' before numeric constant
    6 |     for(i=0;i<n;i++0){
      |        ~           ^
      |                    )
main.c:14:25: error: expected ';' before '}' token
   14 |                 min=c[i]
      |                         ^
      |                         ;
   15 |             }
      |             ~
Language: C

#include <stdio.h>
int main(){
    int n=0,t=0,c[2000],time[2000],i=0,min=10000;
    scanf("%d",&n);
    scanf("%d",&t);
    for(i=0;i<n;i++0){
        scanf("%d",c[i]);
        scanf("%d",time[i]);
    }

    for(i=0;i<n;i++){
        if(time[i]<=t){
            if(c[i]<min){
                min=c[i]
            }
        }
    }
    
    if(min==10000){
        printf("TLE");
    }else{
        printf("%d",min);
    }

    return 0;
}    

Compiler output:
main.c: In function 'main':
main.c:6:20: error: expected ')' before numeric constant
    6 |     for(i=0;i<n;i++0){
      |        ~           ^
      |                    )
main.c:14:25: error: expected ';' before '}' token
   14 |                 min=c[i]
      |                         ^
      |                         ;
   15 |             }
      |             ~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {  
  int n, t;
  cin >> n>> t;
    vector<int> A(n), B(n);
    for (int i = 0; i < n; i++) {
        cin >> A.at(i) >> B.at(i);
    }
  int kotae=1001;
    for (int j = 0; j < n; j++) {
if (t>=B.at(j) && kotae>A.at(j)){kotae=A.at(j)}
    }
 

 
    if (kotae<1001) {
        cout << kotae << endl;
    }
    else {
        cout << "TLE" << endl;
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:47: error: expected ';' before '}' token
   13 | if (t>=B.at(j) && kotae>A.at(j)){kotae=A.at(j)}
      |                                               ^
      |                                               ;
Language: Java

import Java.util.Scanner;

class Main {

	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int time = sc.nextInt();
		int c[] = new int[n];
		int t[] = new int[n];
		int min = -1;
		for (int i = 0; i < n; i++) {
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
			if (t[i] <= time && (c[i] < min || min == -1))
				min = c[i];
		}
		System.out.println(min==-1 ? "TLE\n" : min);
	}
}

Compiler output:
Main.java:1: error: package Java.util does not exist
import Java.util.Scanner;
                ^
Main.java:6: error: cannot find symbol
		Scanner sc = new Scanner(System.in);
		^
  symbol:   class Scanner
  location: class Main
Main.java:6: error: cannot find symbol
		Scanner sc = new Scanner(System.in);
		                 ^
  symbol:   class Scanner
  location: class Main
3 errors
Language: Java

class Main {

	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int time = sc.nextInt();
		int c[] = new int[n];
		int t[] = new int[n];
		int min = -1;
		for (int i = 0; i < n; i++) {
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
			if (t[i] <= time && (c[i] < min || min == -1))
				min = c[i];
		}
		System.out.println(min==-1 ? "TLE\n" : min);
	}
}

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

#include <iostream>
#include <vector>

using namespace std;

int main(void){
  int n,t_limit;

  cin >> n >> t_limit;

  vector<int> c(n);
  vector<int> t(n);
  int min;

  for(int i=0; i<n; i++){
    cin >> c[i] >> t[i]; 
    if(t[i] > t_limit){
       c[i] = 1001;
    }
  }

  min = *min_element(c.begin(), c.end());
  if(min <= 1000) {
    cout << min << endl;
  } else {
    cout << "TLE" << endl;
  }
}
  


Compiler output:
a.cc: In function 'int main()':
a.cc:22:10: error: 'min_element' was not declared in this scope
   22 |   min = *min_element(c.begin(), c.end());
      |          ^~~~~~~~~~~
Language: C++

#include <iostream>
#include <vector>

using namespace std;

int main(void){
  int n,t_limit;

  cin >> n >> t_limit;

  vector<int> c(n);
  vector<int> t(n);

  for(int i=0; i<n; i++){
    cin >> c[i] >> t[i]; 
    if(t[i] > t_limit){
       c[i] = 1001;
    }
  }

  int min = *min_element(c.begin(), c.end());
  if(min <= 1000) {
    cout << min << endl;
  } else {
    cout << "TLE" << endl;
  }
}
  


Compiler output:
a.cc: In function 'int main()':
a.cc:21:14: error: 'min_element' was not declared in this scope
   21 |   int min = *min_element(c.begin(), c.end());
      |              ^~~~~~~~~~~
Language: C++

#include <iostream>
#include <vector>

using namespace std;

int main(void){
  int n,t_limit;

  cin >> n >> t_limit;

  vector<int> c(n);
  vector<int> t(n);

  for(int i=0; i<n; i++){
    cin >> c[i] >> t[i]; 
  }

  for(int i=0; i<n; i++){
    if(t[i] > t_limit){
       c[i] = 1001;
    }
  }

  int min = *min_element(c.begin(), c.end());
  if(min < 1001) {
    cout << min << endl;
  } else {
    cout << "TLE" << endl;
  }
}
  


Compiler output:
a.cc: In function 'int main()':
a.cc:24:14: error: 'min_element' was not declared in this scope
   24 |   int min = *min_element(c.begin(), c.end());
      |              ^~~~~~~~~~~
Language: C++

#include <iostream>

using namespace std;

int main(void){
  int n,t_limit;

  cin >> n >> t_limit;

  vector<int> c(n),t(n);

  for(int i=0; i<n; i++){
    cin >> c(i) >> t(i); 
  }

  for(int i=0; i<n; i++){
    if(t(i) > t_limit){
       c(i) = 1001;
    }
  }

  int min = *std::min_element(c.begin(), c.end());
  if(min < 1001) {
    cout << min << endl;
  } else {
    cout << TLE << endl;
  }
}
  


Compiler output:
a.cc: In function 'int main()':
a.cc:10:3: error: 'vector' was not declared in this scope
   10 |   vector<int> c(n),t(n);
      |   ^~~~~~
a.cc:2:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    1 | #include <iostream>
  +++ |+#include <vector>
    2 | 
a.cc:10:10: error: expected primary-expression before 'int'
   10 |   vector<int> c(n),t(n);
      |          ^~~
a.cc:13:12: error: 'c' was not declared in this scope
   13 |     cin >> c(i) >> t(i);
      |            ^
a.cc:13:20: error: 't' was not declared in this scope
   13 |     cin >> c(i) >> t(i);
      |                    ^
a.cc:17:8: error: 't' was not declared in this scope
   17 |     if(t(i) > t_limit){
      |        ^
a.cc:18:8: error: 'c' was not declared in this scope
   18 |        c(i) = 1001;
      |        ^
a.cc:22:19: error: 'min_element' is not a member of 'std'; did you mean 'tuple_element'?
   22 |   int min = *std::min_element(c.begin(), c.end());
      |                   ^~~~~~~~~~~
      |                   tuple_element
a.cc:22:31: error: 'c' was not declared in this scope
   22 |   int min = *std::min_element(c.begin(), c.end());
      |                               ^
a.cc:26:13: error: 'TLE' was not declared in this scope
   26 |     cout << TLE << endl;
      |             ^~~
Language: C++

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

int main(){
	int n,t;
	cin>>n>>t;
	int c[n+1],t[n+1];
	for(int i=1;i<=n;i++){
		cin>>c[i]>>t[i];
	}
	int minn=t+1;
	for(int i=1;i<=n;i++){
		if(t[i]<t){
			if(c[i]<minn) minn=c[i];
		}
	}
	cout<<minn;
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:20: error: conflicting declaration 'int t [(n + 1)]'
    7 |         int c[n+1],t[n+1];
      |                    ^
a.cc:5:15: note: previous declaration as 'int t'
    5 |         int n,t;
      |               ^
a.cc:9:29: error: invalid types 'int[int]' for array subscript
    9 |                 cin>>c[i]>>t[i];
      |                             ^
a.cc:13:21: error: invalid types 'int[int]' for array subscript
   13 |                 if(t[i]<t){
      |                     ^
Language: C++


N, T = [int(s) for s in input().split()]

c = []
t = []
for n in N:
    inputs = input().split()
    c.append(int(inputs[0]))
    t.append(int(inputs[1]))

min_cost = None
for i in range(N):
    if t[i] <= T and (min_cost is None or c[i] <= min_cost):
        min_cost = c[i]
        result = i

return i

Compiler output:
a.cc:2:1: error: 'N' does not name a type
    2 | N, T = [int(s) for s in input().split()]
      | ^
Language: C++

#include<iostream>
using namespace std;

int main(){
  int N,T,min=1001;
  cin>>N>>T;
  
  int c[N+1],t[N+1]
  
  for(int i=1; i<N+1; i++) cin>>c[i]>>t[i];
  
  for(int i=1; i<N+1; i++){
    if(t[i]<=T&&c[i]<min) min=c[i];
    }
  if(max==1001) cout<<"TLE"<<endl;
  else cout<<min<<endl;
  
  return 0;
}
      
      
  

Compiler output:
a.cc: In function 'int main()':
a.cc:10:3: error: expected initializer before 'for'
   10 |   for(int i=1; i<N+1; i++) cin>>c[i]>>t[i];
      |   ^~~
a.cc:10:16: error: 'i' was not declared in this scope
   10 |   for(int i=1; i<N+1; i++) cin>>c[i]>>t[i];
      |                ^
a.cc:13:8: error: 't' was not declared in this scope
   13 |     if(t[i]<=T&&c[i]<min) min=c[i];
      |        ^
a.cc:15:9: error: invalid operands of types '<unresolved overloaded function type>' and 'int' to binary 'operator=='
   15 |   if(max==1001) cout<<"TLE"<<endl;
      |      ~~~^~~~~~
Language: C++

#include<iostream>
#include<string>
#include<algorithm>
#include<vector>
#include<iomanip>
#include<math.h>
#include<complex>
#include<queue>
#include<deque>
#include<stack>
#include<map>
#include<set>
#include<bitset>
using namespace std;
#define REP(i,m,n) for(int i=(int)m ; i < (int) n ; ++i )
#define rep(i,n) REP(i,0,n)
typedef long long ll;
typedef pair<int,int> pint;
typedef pair<ll,int> pli;
const int inf=1e9+7;
const ll longinf=1LL<<60 ;
const ll mod=1e9+7 ;

    using namespace std;
 
int b[200010]={1};

    int main(){
      int n,t;
      cin >> n >> T;
      int c[n],t[n];
      rep(i,n)cin >> c[i] >> t[i];
      int ans=inf;
      rep(i,n){
       if(c[i]*t[i]<=T)min(ans,c[i]*t[i]); 
      }
      cout << ans << endl;

Compiler output:
a.cc: In function 'int main()':
a.cc:30:19: error: 'T' was not declared in this scope
   30 |       cin >> n >> T;
      |                   ^
a.cc:31:16: error: conflicting declaration 'int t [n]'
   31 |       int c[n],t[n];
      |                ^
a.cc:29:13: note: previous declaration as 'int t'
   29 |       int n,t;
      |             ^
a.cc:32:31: error: invalid types 'int[int]' for array subscript
   32 |       rep(i,n)cin >> c[i] >> t[i];
      |                               ^
a.cc:35:17: error: invalid types 'int[int]' for array subscript
   35 |        if(c[i]*t[i]<=T)min(ans,c[i]*t[i]);
      |                 ^
a.cc:35:38: error: invalid types 'int[int]' for array subscript
   35 |        if(c[i]*t[i]<=T)min(ans,c[i]*t[i]);
      |                                      ^
a.cc:37:27: error: expected '}' at end of input
   37 |       cout << ans << endl;
      |                           ^
a.cc:28:15: note: to match this '{'
   28 |     int main(){
      |               ^
Language: C++

n,T = map(int,input().split())

ans = 12345

for i in range(n):
    c,t = map(int,input().split())
    if t <= T:
        ans = min(ans,c)

if ans == 12345:
    print("TLE")
else:
    print(ans)
        

Compiler output:
a.cc:1:1: error: 'n' does not name a type
    1 | n,T = map(int,input().split())
      | ^
Language: C++

//TimeLimitExceeded.cpp
#include <iostream>

using namespace std;

int main () {
  int N; int T; 
  cin >> N;
  cin >> T;
 
  int min = INT_MAX;
  int c, t;
  for (int j = 0; j <= N-1; j++) {
    cin >> c >> t;
    if (t <= T){
      if(min > c) {
        min = c;
      }
    }
  }
  if (min > 1000) {
    cout << "TLE" << endl;
  } else {
  cout << min << endl;
  }
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:13: error: 'INT_MAX' was not declared in this scope
   11 |   int min = INT_MAX;
      |             ^~~~~~~
a.cc:3:1: note: 'INT_MAX' is defined in header '<climits>'; this is probably fixable by adding '#include <climits>'
    2 | #include <iostream>
  +++ |+#include <climits>
    3 |
Language: C++

#include<iostream>
#include<algorithm>
#include<vector>
using namespace std;
int main()
{
  int N, T; cin >> N >> T;
  vector<int> c(N);
  vector<int> t(N);
  for(int i = 0; i < N; i++){
    cin >> c[i] >> t[i];
  }

  vector<int> a;
  for(int a = 0; a < N; ++a){
    if(t[i] <= T){
      a.push_back(c[i]);
    }
  }
  if(a.size() == 0){
    cout << "TLE" << endl;
  }
  else {
    cout << *min_element(a.begin(), a.end()) << endl;
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:16:10: error: 'i' was not declared in this scope
   16 |     if(t[i] <= T){
      |          ^
a.cc:17:9: error: request for member 'push_back' in 'a', which is of non-class type 'int'
   17 |       a.push_back(c[i]);
      |         ^~~~~~~~~
Language: C++

#include<iostream>
#include<algorithm>
#include<vector>
using namespace std;
int main()
{
  int N, T; cin >> N >> T;
  vector<int> c(N);
  vector<int> t(N);
  vector<int> a(0);
  for(int i = 0; i < N; i++){
    cin >> c[i] >> t[i];
    if(t[i] < T){
      a[i] = c[i];
    }

  }
  int n = a.size();
  if(n == 0){
    cout << "TLE" << endl;
  }
  else {
    sort(a.begin(), a.back());
    int b = a.front();
    cout << b << endl;
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:23:9: error: no matching function for call to 'sort(std::vector<int>::iterator, __gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type&)'
   23 |     sort(a.begin(), a.back());
      |     ~~~~^~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/algorithm:61,
                 from a.cc:2:
/usr/include/c++/14/bits/stl_algo.h:4762:5: note: candidate: 'template<class _RAIter> void std::sort(_RAIter, _RAIter)'
 4762 |     sort(_RandomAccessIterator __first, _RandomAccessIterator __last)
      |     ^~~~
/usr/include/c++/14/bits/stl_algo.h:4762:5: note:   template argument deduction/substitution failed:
a.cc:23:9: note:   deduced conflicting types for parameter '_RAIter' ('__gnu_cxx::__normal_iterator<int*, std::vector<int> >' and 'int')
   23 |     sort(a.begin(), a.back());
      |     ~~~~^~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/stl_algo.h:4793:5: note: candidate: 'template<class _RAIter, class _Compare> void std::sort(_RAIter, _RAIter, _Compare)'
 4793 |     sort(_RandomAccessIterator __first, _RandomAccessIterator __last,
      |     ^~~~
/usr/include/c++/14/bits/stl_algo.h:4793:5: note:   candidate expects 3 arguments, 2 provided
In file included from /usr/include/c++/14/algorithm:86:
/usr/include/c++/14/pstl/glue_algorithm_defs.h:292:1: note: candidate: 'template<class _ExecutionPolicy, class _RandomAccessIterator, class _Compare> __pstl::__internal::__enable_if_execution_policy<_ExecutionPolicy, void> std::sort(_ExecutionPolicy&&, _RandomAccessIterator, _RandomAccessIterator, _Compare)'
  292 | sort(_ExecutionPolicy&& __exec, _RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp);
      | ^~~~
/usr/include/c++/14/pstl/glue_algorithm_defs.h:292:1: note:   candidate expects 4 arguments, 2 provided
/usr/include/c++/14/pstl/glue_algorithm_defs.h:296:1: note: candidate: 'template<class _ExecutionPolicy, class _RandomAccessIterator> __pstl::__internal::__enable_if_execution_policy<_ExecutionPolicy, void> std::sort(_ExecutionPolicy&&, _RandomAccessIterator, _RandomAccessIterator)'
  296 | sort(_ExecutionPolicy&& __exec, _RandomAccessIterator __first, _RandomAccessIterator __last);
      | ^~~~
/usr/include/c++/14/pstl/glue_algorithm_defs.h:296:1: note:   candidate expects 3 arguments, 2 provided
Language: C++

#include<iostream>
#include<algorithm>
#include<vector>
using namespace std;
int main()
{
  int N, T; cin >> N >> T;
  vector<int> c(N);
  vector<int> t(N);
  vector<int> a(0);
  for(int i = 0; i < N; i++){
    cin >> c[i] >> t[i];
    if(t[i] < T){
      a[i] = c[i];
    }

  }
  n = a.size();
  if(n == 0){
    cout << "TLE" << endl;
  }
  else {
    sort(a.end(), a.begin());
    int b = a.back();
    cout << b << endl;
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:18:3: error: 'n' was not declared in this scope
   18 |   n = a.size();
      |   ^
Language: C++

#include<iostream>
#include<algorithm>
#include<vector>
using namespace std;
int main()
{
  int N, T; cin >> N >> T;
  vector<int> c(N);
  vector<int> t(N);
  vector<int> a(0);
  for(int i = 0; i < N; i++){
    cin >> c[i] >> t[i];
    if(t[i] < T){
      a[i] = c[i];
    }
    
  }
  sort(a.begin(), a.end());
  int b = a.end();
  cout << b << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:19:16: error: cannot convert 'std::vector<int>::iterator' to 'int' in initialization
   19 |   int b = a.end();
      |           ~~~~~^~
      |                |
      |                std::vector<int>::iterator
Language: C++

#include<iostream>
#include<algorithm>
#include<vector>
using namespace std;
int main()
{
  int N, T; cin >> N >> T;
  vector<int> c(N);
  vector<int> t(N);
  vector<int> a(0);
  for(int i = 0; i < N; i++){
    cin >> c[i] >> t[i];
    if(t[i] < T){
      a = t;
    }
  }
  sort(a);
  b = a.end();
  cout << b << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:17:7: error: no matching function for call to 'sort(std::vector<int>&)'
   17 |   sort(a);
      |   ~~~~^~~
In file included from /usr/include/c++/14/algorithm:61,
                 from a.cc:2:
/usr/include/c++/14/bits/stl_algo.h:4762:5: note: candidate: 'template<class _RAIter> void std::sort(_RAIter, _RAIter)'
 4762 |     sort(_RandomAccessIterator __first, _RandomAccessIterator __last)
      |     ^~~~
/usr/include/c++/14/bits/stl_algo.h:4762:5: note:   candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/stl_algo.h:4793:5: note: candidate: 'template<class _RAIter, class _Compare> void std::sort(_RAIter, _RAIter, _Compare)'
 4793 |     sort(_RandomAccessIterator __first, _RandomAccessIterator __last,
      |     ^~~~
/usr/include/c++/14/bits/stl_algo.h:4793:5: note:   candidate expects 3 arguments, 1 provided
In file included from /usr/include/c++/14/algorithm:86:
/usr/include/c++/14/pstl/glue_algorithm_defs.h:292:1: note: candidate: 'template<class _ExecutionPolicy, class _RandomAccessIterator, class _Compare> __pstl::__internal::__enable_if_execution_policy<_ExecutionPolicy, void> std::sort(_ExecutionPolicy&&, _RandomAccessIterator, _RandomAccessIterator, _Compare)'
  292 | sort(_ExecutionPolicy&& __exec, _RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp);
      | ^~~~
/usr/include/c++/14/pstl/glue_algorithm_defs.h:292:1: note:   candidate expects 4 arguments, 1 provided
/usr/include/c++/14/pstl/glue_algorithm_defs.h:296:1: note: candidate: 'template<class _ExecutionPolicy, class _RandomAccessIterator> __pstl::__internal::__enable_if_execution_policy<_ExecutionPolicy, void> std::sort(_ExecutionPolicy&&, _RandomAccessIterator, _RandomAccessIterator)'
  296 | sort(_ExecutionPolicy&& __exec, _RandomAccessIterator __first, _RandomAccessIterator __last);
      | ^~~~
/usr/include/c++/14/pstl/glue_algorithm_defs.h:296:1: note:   candidate expects 3 arguments, 1 provided
a.cc:18:3: error: 'b' was not declared in this scope
   18 |   b = a.end();
      |   ^
Language: C++

#include<iostream>
#include<algorithm>
#include<vector>
using namespace std;
int main()
{
  int N, T; cin >> N >> T;
  vector<int> c(N);
  vector<int> t(N);
  vector<int> a(0);
  for(int i = 0; i < N; i++){
    cin >> c[i] >> t[i];
    if(t[i] < T){
      a[i] = t;
    }
  }
  sort(a);
  b = a.end();
  cout << b << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:14: error: cannot convert 'std::vector<int>' to '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type' {aka 'int'} in assignment
   14 |       a[i] = t;
      |              ^
      |              |
      |              std::vector<int>
a.cc:17:7: error: no matching function for call to 'sort(std::vector<int>&)'
   17 |   sort(a);
      |   ~~~~^~~
In file included from /usr/include/c++/14/algorithm:61,
                 from a.cc:2:
/usr/include/c++/14/bits/stl_algo.h:4762:5: note: candidate: 'template<class _RAIter> void std::sort(_RAIter, _RAIter)'
 4762 |     sort(_RandomAccessIterator __first, _RandomAccessIterator __last)
      |     ^~~~
/usr/include/c++/14/bits/stl_algo.h:4762:5: note:   candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/stl_algo.h:4793:5: note: candidate: 'template<class _RAIter, class _Compare> void std::sort(_RAIter, _RAIter, _Compare)'
 4793 |     sort(_RandomAccessIterator __first, _RandomAccessIterator __last,
      |     ^~~~
/usr/include/c++/14/bits/stl_algo.h:4793:5: note:   candidate expects 3 arguments, 1 provided
In file included from /usr/include/c++/14/algorithm:86:
/usr/include/c++/14/pstl/glue_algorithm_defs.h:292:1: note: candidate: 'template<class _ExecutionPolicy, class _RandomAccessIterator, class _Compare> __pstl::__internal::__enable_if_execution_policy<_ExecutionPolicy, void> std::sort(_ExecutionPolicy&&, _RandomAccessIterator, _RandomAccessIterator, _Compare)'
  292 | sort(_ExecutionPolicy&& __exec, _RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp);
      | ^~~~
/usr/include/c++/14/pstl/glue_algorithm_defs.h:292:1: note:   candidate expects 4 arguments, 1 provided
/usr/include/c++/14/pstl/glue_algorithm_defs.h:296:1: note: candidate: 'template<class _ExecutionPolicy, class _RandomAccessIterator> __pstl::__internal::__enable_if_execution_policy<_ExecutionPolicy, void> std::sort(_ExecutionPolicy&&, _RandomAccessIterator, _RandomAccessIterator)'
  296 | sort(_ExecutionPolicy&& __exec, _RandomAccessIterator __first, _RandomAccessIterator __last);
      | ^~~~
/usr/include/c++/14/pstl/glue_algorithm_defs.h:296:1: note:   candidate expects 3 arguments, 1 provided
a.cc:18:3: error: 'b' was not declared in this scope
   18 |   b = a.end();
      |   ^
Language: C++

#include<iostream>
#include<algorithm>
using namespace std;
int main()
{
  int N, T; cin >> N >> T;
  vector<int> c(N);
  vector<int> t(N);
  vector<int> a(0);
  for(int i = 0; i < N; i++){
    cin >> c[i] >> t[i];
    if(t[i] < T){
      a[i] = t;
    }
  }
  sort(a);
  b = a.end();
  cout << b << endl;
  
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:3: error: 'vector' was not declared in this scope
    7 |   vector<int> c(N);
      |   ^~~~~~
a.cc:3:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    2 | #include<algorithm>
  +++ |+#include <vector>
    3 | using namespace std;
a.cc:7:10: error: expected primary-expression before 'int'
    7 |   vector<int> c(N);
      |          ^~~
a.cc:8:10: error: expected primary-expression before 'int'
    8 |   vector<int> t(N);
      |          ^~~
a.cc:9:10: error: expected primary-expression before 'int'
    9 |   vector<int> a(0);
      |          ^~~
a.cc:11:12: error: 'c' was not declared in this scope
   11 |     cin >> c[i] >> t[i];
      |            ^
a.cc:11:20: error: 't' was not declared in this scope
   11 |     cin >> c[i] >> t[i];
      |                    ^
a.cc:13:7: error: 'a' was not declared in this scope
   13 |       a[i] = t;
      |       ^
a.cc:16:8: error: 'a' was not declared in this scope
   16 |   sort(a);
      |        ^
a.cc:17:3: error: 'b' was not declared in this scope
   17 |   b = a.end();
      |   ^
Language: C++

#include <iostream>
#include <map.h>
using namespace std;
 
int main()
{
    int n , T , c , t ;
    map <int , int> mp;
    cin >> n >> T ;
    while(n--){
        cin>>c>>t;
        mp[c]=t;
    }
    int ans = -1;
    map <int , int> :: iterator it ;
    for(it = mp.begin() ; it!=mp.end() ; it++){
        if(it->second <= T){
            ans = it->first;
            break;
        }
    }
    if(ans == -1) cout<<"TLE"<<endl;
    else cout << ans<<endl;
    return 0;
}

Compiler output:
a.cc:2:10: fatal error: map.h: No such file or directory
    2 | #include <map.h>
      |          ^~~~~~~
compilation terminated.
Language: C++

#include <iostream>
using namespace std;

int main()
{
    int n , T , c , t ;
    map <int , int> mp;
    cin >> n >> T ;
    while(n--){
        cin>>c>>t;
        mp[c]=t;
    }
    int ans = -1;
    map <int , int> :: iterator it ;
    for(it = mp.begin() ; it!=mp.end() ; it++){
        if(it->second <= T){
            ans = it->first;
            break;
        }
    }
    if(ans == -1) cout<<"TLE"<<endl;
    else cout << ans<<endl;
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: 'map' was not declared in this scope
    7 |     map <int , int> mp;
      |     ^~~
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 | using namespace std;
a.cc:7:10: error: expected primary-expression before 'int'
    7 |     map <int , int> mp;
      |          ^~~
a.cc:11:9: error: 'mp' was not declared in this scope
   11 |         mp[c]=t;
      |         ^~
a.cc:14:10: error: expected primary-expression before 'int'
   14 |     map <int , int> :: iterator it ;
      |          ^~~
a.cc:15:9: error: 'it' was not declared in this scope; did you mean 't'?
   15 |     for(it = mp.begin() ; it!=mp.end() ; it++){
      |         ^~
      |         t
a.cc:15:14: error: 'mp' was not declared in this scope
   15 |     for(it = mp.begin() ; it!=mp.end() ; it++){
      |              ^~
Language: C++

#include <iostream>

int main(){
  int N, T;
  std::cin>>N>>T;
  const long long NUM = 1000000000;
  long long k_c = NUM;
  long long k_t = NUM;

  for(int i = 0;i < N;i++){
    int c, t;
    std::cin>>c>>t;
    if(c <= k_c && t <= t_c && t < T){
      k_c = c;
      t_c = t;
    }
  }
  if(k_c == NUM){
    std::cout<<"TLE"<<std::endl;
  }else{
    std::cout<<k_c<<std::endl;
  }
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:25: error: 't_c' was not declared in this scope; did you mean 'k_c'?
   13 |     if(c <= k_c && t <= t_c && t < T){
      |                         ^~~
      |                         k_c
Language: C++

#include<algorithm>
#include<vector>
#include<iostream>

using namespace std;

int main(){
  int N, T; cin >> N >> T;
  vector<int> c(N);
  vector<int> t(N);
  for (int i = 0; i < N; i++){
    cin >> c[i] >> t[i];
  }
  int MAX = 1 << 30;
  int ans = MAX;
  for (int i = 0;i < N; i++ ){
    if(t[i] < T){
      ans = min(ans, c[i]);
    }
  }
  if (ans < MAX){
    cout << "TLE" << endl;
  }
  else {
    cout << ans << endl
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:25:24: error: expected ';' before '}' token
   25 |     cout << ans << endl
      |                        ^
      |                        ;
   26 |   }
      |   ~
Language: C++

#include<algorithm>
#include<vector>
#include<iostream>

using namespace std;

int main(){
  int N, T; cin >> N >> T;
  vector<int> c(N);
  vector<int> t(N);
  for (int i = 0; i < N; i++){
    cin >> c[i] >> t[i];
  }
  int MAX = 1 << 30;
  int ans = MAX;
  for (int i = 0;i < N; i++ ){
    if(t[i] <= T){
      ans = min(ans, c[i]);
    }
  if (ans < MAX){
    cout << "TLE" << endl;
  }
  else {
    cout << ans << endl
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:24:24: error: expected ';' before '}' token
   24 |     cout << ans << endl
      |                        ^
      |                        ;
   25 |   }
      |   ~                     
a.cc:26:2: error: expected '}' at end of input
   26 | }
      |  ^
a.cc:7:11: note: to match this '{'
    7 | int main(){
      |           ^
Language: C++

#include<algorithm>
#include<vector>
#include<iostream>

using namespace std;

int main(){
  int N, T; cin >> N >> T;
  vector<int> c(N);
  vector<int> t(N);
  for (int i = 0; i < N; i++){
    cin >> c[i] >> t[i];
  }
  int MAX = 1 << 30;
  int ans = MAX;
  for (int i = 0;i < N; i++ ){
    if(t[i] < T){
      ans = min(ans, c[i]);
    }
  if (ans < MAX){
    cout << "TLE" << endl;
  }
  else {
    cout << ans << endl
  }
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:24:24: error: expected ';' before '}' token
   24 |     cout << ans << endl
      |                        ^
      |                        ;
   25 |   }
      |   ~
Language: C++

#include<algorithm>
#include<vector>
#include<iostream>

using namespace std;

int main(){
  int N, T; cin >> N >> T;
  int c(N), t(N);
  for (int i = 0; i < N; i++){
    cin >> c[i] >> t[i];
  }
  int MAX = 1 << 30;
  int ans = MAX;
  for (int i = 0;i < N; i++ ){
    if(t[i] < T){
      ans = min(ans, c[i]);
    }
  if (ans < MAX){
    cout << "TLE" << endl;
  }
  else {
    cout << ans << endl
  }
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:11:13: error: invalid types 'int[int]' for array subscript
   11 |     cin >> c[i] >> t[i];
      |             ^
a.cc:11:21: error: invalid types 'int[int]' for array subscript
   11 |     cin >> c[i] >> t[i];
      |                     ^
a.cc:16:9: error: invalid types 'int[int]' for array subscript
   16 |     if(t[i] < T){
      |         ^
a.cc:17:23: error: invalid types 'int[int]' for array subscript
   17 |       ans = min(ans, c[i]);
      |                       ^
a.cc:23:24: error: expected ';' before '}' token
   23 |     cout << ans << endl
      |                        ^
      |                        ;
   24 |   }
      |   ~
Language: C++

// doot diddly donger cuckerino Hahahahahah

#include<bits/stdc++.h>

using namespace std;

typedef long long int LL;
typedef unsigned int UINT;
typedef unsigned long long ULL;
typedef pair<int, int> PII;
typedef pair<string, int> PSI;
typedef pair<LL, LL> PLL;
typedef vector<int> VI;
typedef vector<string> VS;
typedef vector<bool> VB;
typedef vector<PII> VPII;
typedef vector<PLL> VPLL;
typedef vector<LL> VLL;
typedef tuple<int,int,int> TPL;
typedef priority_queue<int> pqueue;
typedef priority_queue<int,VI,greater<int>> pdqueue;

const int dx[] = {-1, 0, 1, 0, -1, -1, 1, 1};
const int dy[] = {0, 1, 0, -1, -1, 1, -1, 1};
const int dxhorse[] = {-2, -2, -1, -1, 1, 1, 2, 2};
const int dyhorse[] = {1, -1, 2, -2, 2, -2, 1, -1};

#define MP make_pair
#define MT make_tuple
#define PB push_back
#define EB emplace_back
#define endl "\n"
#define UNIQUE(X) (X).erase(unique(all(X)),(X).end())
#define F first
#define S second
#define SZ(x)           (x).size()
#define MAX(a, b)      ((a)>(b)?(a):(b))
#define MIN(a, b)      ((a)<(b)?(a):(b))
#define ALL(a)         std::begin(a), std::end(a)
#define Fill(n, x)      memset(n,x,sizeof n);
#define IN_REP         int _t; cin >> _t ; while(_t--)
#define IOS            ios::sync_with_stdio(false);cin.tie(NULL)
#define FOR(i, a, b)    for(int i=(a);i<(b);i++)
#define REP(i, n)       FOR(i,0,n)
#define FORR(i, n)      for(int i=(n);i>=0;i--)
#define EPS (double) 1e-9
#define MOD (1000*1000*1000 + 7)
#define INF 1011111111
#define LLINF 1000111000111000111LL
#define MAXN 5000007

int main() {
    IOS;
    int n,t;
    cin >> n >>T;
    VPII c(n);
    REP(i,n){
      int x,y;
      cin >> x >>y;
      c[i] = MP(y,x);
    }
    PII p = lower_bound(ALL(c));
    cout << p.S << endl;
    
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:55:16: error: 'T' was not declared in this scope
   55 |     cin >> n >>T;
      |                ^
a.cc:62:24: error: no matching function for call to 'lower_bound(std::vector<std::pair<int, int> >::iterator, std::vector<std::pair<int, int> >::iterator)'
   62 |     PII p = lower_bound(ALL(c));
      |             ~~~~~~~~~~~^~~~~~~~
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:3:
/usr/include/c++/14/bits/stl_algobase.h:1530:5: note: candidate: 'template<class _ForwardIterator, class _Tp> _ForwardIterator std::lower_bound(_ForwardIterator, _ForwardIterator, const _Tp&)'
 1530 |     lower_bound(_ForwardIterator __first, _ForwardIterator __last,
      |     ^~~~~~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:1530:5: note:   candidate expects 3 arguments, 2 provided
In file included from /usr/include/c++/14/algorithm:61:
/usr/include/c++/14/bits/stl_algo.h:1963:5: note: candidate: 'template<class _FIter, class _Tp, class _Compare> _FIter std::lower_bound(_FIter, _FIter, const _Tp&, _Compare)'
 1963 |     lower_bound(_ForwardIterator __first, _ForwardIterator __last,
      |     ^~~~~~~~~~~
/usr/include/c++/14/bits/stl_algo.h:1963:5: note:   candidate expects 4 arguments, 2 provided
Language: C

#include <stdio.h>
 
int main()
{
        int N,T,i,m=0,cost;
        scanf("%d %d",&N,&T);
        int c[N],t[N];
 
        for (i=0;i<n;i++)
                scanf("%d %d",&c[i],&t[i]);
 
        cost = c[0];
        for (i=0;i<N;i++)
                if ((t[i]<=T)&&(c[i]<=cost)){
                        cost = c[i];
                        m++;
        }
 
        if (m==0)printf("TLE\n");
        else printf("%d\n",cost);
 
        return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:20: error: 'n' undeclared (first use in this function)
    9 |         for (i=0;i<n;i++)
      |                    ^
main.c:9:20: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>
 
int main()
{
        int N,T,i,m=0,cost;
        scanf("%d %d",&N,&T);
        int c[N],t[N];
 
        for (i=0;i<n;i++)
                scanf("%d %d",&c[i],&t[i]);
 
        cost = c[0];
        for (i=0;i<n;i++)
                if ((t[i]<=T)&&(c[i]<=cost)){
                        cost = c[i];
                        m++;
        }
 
        if (m==0)printf("TLE\n");
        else printf("%d\n",cost);
 
        return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:20: error: 'n' undeclared (first use in this function)
    9 |         for (i=0;i<n;i++)
      |                    ^
main.c:9:20: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>

int main(void)
{
        int n,T,i,min,cost;

        scanf("%d %d",&n,&T);

        int c[n],t[n];

        for (i=0;i<n;i++)
                scanf("%d %d",&c[i],&t[i]);

        min = T;

        for (i=0;i<n;i++)
                if (t[i]<min){
                        min = t[i];
                        cost = c[i];
        }

        if (min==T)
                printf("TEL\n");
        else
                printf("%d\n",cost);

        return 0;


Compiler output:
main.c: In function 'main':
main.c:27:9: error: expected declaration or statement at end of input
   27 |         return 0;
      |         ^~~~~~
Language: C

#include <stdio.h>
 
int main(void){
    int n,a;
    scanf("%d %d",&n,&a);
    int c[n];
    int t[a];
    int mincost = 1001;
    int mintime = 1001;
    for(int i = 0;i<n;i++){
        scanf("%d %d",&c[i],&t[i]);
        if(c[i] <= mincost && t[i] <= a){
            mincost = c[i];
            mintime = c[i];
        }
    }
    if(mincost == 1001){
        printf("TLE\n");
    }else{
        printf("%d\n",mincost);
    }


Compiler output:
main.c: In function 'main':
main.c:21:5: error: expected declaration or statement at end of input
   21 |     }
      |     ^