Language: Java

#pragma GCC optimize(2)

#include "bits/stdc++.h"

using namespace std;

#define all(a) begin(a), end(a)
#define MOD 1000000007
#define PII pair<int, int>
#define REP(x, l, u) for (ll x = l; x < u; x++)
#define RED(x, l, u) for (ll x = l; x >= u; x--)
#define complete_unique(a) a.erase(unique(begin(a), end(a)), end(a))
#define mst(x, a) memset(x, a, sizeof(x))
typedef vector<int> VI;
typedef long long ll;

ll quick_pow(ll a, ll b) {
    long long res = 1;
    while (b) {
        if (b & 1) {
            res = a * res;
        }
        a = a * a;
        b >>= 1;
    }
    return res;
}

ll gcd(ll a, ll b) {
    a = abs(a), b = abs(b);
    while (b != 0) {
        a %= b;
        swap(a, b);
    }
    return a;
}

bool is_prime(int n) {
    if (n == 0)return false;
    if (n == 1)return false;
    if (n == 2)return true;
    if (n % 2 == 0)
        return false;
    int j = sqrt(n);
    for (int i = 2; i <= j; ++i) {
        if (n % i == 0)
            return false;
    }
    return true;
}

ll reverse_num(ll n) {
    ll x = 0, t = n;
    while (t != 0) {
        x = x * 10 + t % 10;
        t /= 10;
    }
    return x;
}

void solve() {
    //    freopen("C:\\Users\\26019\\Downloads\\P1195_4.in", "r", stdin);
    //    fclose(stdin);
    int t = 1;
//    cin >> t;
    while (t--) {
        int x;
        cin >> x;
        if (x >=30) cout << "Yes";
        else cout <<"No";
    }
}

int main() {
    // 加速输入和输出
    ios::sync_with_stdio(false);
    cin.tie(nullptr);
    cout.tie(nullptr);
    solve();
    return 0;
}



Compiler output:
Main.java:1: error: illegal character: '#'
#pragma GCC optimize(2)
^
Main.java:3: error: illegal character: '#'
#include "bits/stdc++.h"
^
Main.java:7: error: illegal character: '#'
#define all(a) begin(a), end(a)
^
Main.java:1: error: unnamed classes are a preview feature and are disabled by default.
#pragma GCC optimize(2)
        ^
  (use --enable-preview to enable unnamed classes)
Main.java:7: error: class, interface, enum, or record expected
#define all(a) begin(a), end(a)
        ^
Main.java:8: error: illegal character: '#'
#define MOD 1000000007
^
Main.java:9: error: illegal character: '#'
#define PII pair<int, int>
^
Main.java:10: error: illegal character: '#'
#define REP(x, l, u) for (ll x = l; x < u; x++)
^
Main.java:10: error: class, interface, enum, or record expected
#define REP(x, l, u) for (ll x = l; x < u; x++)
                                    ^
Main.java:10: error: class, interface, enum, or record expected
#define REP(x, l, u) for (ll x = l; x < u; x++)
                                           ^
Main.java:11: error: illegal character: '#'
#define RED(x, l, u) for (ll x = l; x >= u; x--)
^
Main.java:11: error: class, interface, enum, or record expected
#define RED(x, l, u) for (ll x = l; x >= u; x--)
                                    ^
Main.java:11: error: class, interface, enum, or record expected
#define RED(x, l, u) for (ll x = l; x >= u; x--)
                                            ^
Main.java:12: error: illegal character: '#'
#define complete_unique(a) a.erase(unique(begin(a), end(a)), end(a))
^
Main.java:13: error: illegal character: '#'
#define mst(x, a) memset(x, a, sizeof(x))
^
Main.java:15: error: class, interface, enum, or record expected
typedef long long ll;
^
Main.java:18: error: not a statement
    long long res = 1;
    ^
Main.java:18: error: ';' expected
    long long res = 1;
        ^
Main.java:30: error: ';' expected
    a = abs(a), b = abs(b);
              ^
Main.java:68: error: not a statement
        cin >> x;
            ^
Main.java:69: error: not a statement
        if (x >=30) cout << "Yes";
                         ^
Main.java:70: error: not a statement
        else cout <<"No";
                  ^
Main.java:76: error: not a statement
    ios::sync_with_stdio(false);
    ^
Main.java:76: error: ';' expected
    ios::sync_with_stdio(false);
                        ^
24 errors