Language: Java

#include <bits/stdc++.h>
using namespace std;
#define li          long
#define ll          long long
#define ull         unsigned long long
#define ff          first
#define ss          second
#define pii         pair<int,int>
#define pli         pair<li,li>
#define pll         pair<ll,ll>
#define pb          push_back
#define fo(i,k,n)   for(int i = k;i<n; i++)
#define ro(i,k,n)   for(int i = k; i>=n; i--)
#define tc          int t;cin>>t;while(t--)
#define all(v)      v.begin(),v.end()
#define inf         INT_MAX
#define ninf        INT_MIN
#define v(x)        vector<x>
#define int         long long
#define ar(x,y)     array<x,y>
const ll mod1 = 99844353;
const ll mod2 = 1e9+7;
/* template <class T>
using oset = tree<T,null_type,less<T>,rb_tree_tag,tree_order_statistics_node_update>; */

void fastio()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    cout.tie(NULL);
}

int power(int x,int y){
	int res = 1;
	while(y > 0){
	 	if(y & 1) res *= x;
	 	y >>= 1;
	 	x *= x;
	}
	return res;
}

int power(int x,int y,int mod){
 	int res = 1;
 	x %= mod;
 	while(y > 0){
 	 	if(y & 1) res = (res * x) % mod;
 	 	y >>= 1;
 	 	x = (x * x) % mod;
 	}
 	return res;
}

struct dsu{
  unordered_map<int,int> pr,sz;
  dsu(){
    (this->pr).clear();
    (this->sz).clear();
  }
  void make(int x){
    pr[x] = x;
    sz[x] = 1;
  }
  int getpar(int x){
    if(pr[x] == x)return x;
    return pr[x] = getpar(pr[x]);
  }
  void merge(int x,int y){
    x = getpar(x);
    y = getpar(y);
    if(sz[x]<sz[y])swap(x,y);
    pr[y] = x;
    sz[x]+=sz[y];
    sz[y] = 0;
  }
};

class data {
	public:
	int sum,pref,suff,ans;
	data(int val){
	 	this -> sum = val;
   		this -> pref = this -> suff = this -> ans = max(0ll, val);
	}
	data(){}
	data combine(data l,data r){
	 	data res;
    	res.sum = l.sum + r.sum;
    	res.pref = max(l.pref, l.sum + r.pref);
    	res.suff = max(r.suff, r.sum + l.suff);
    	res.ans = max(max(l.ans, r.ans), l.suff + r.pref);
    	return res;
	}
};

class Seg_Tree : public data {
	public :
	int n;
	vector<data> t;
	Seg_Tree(int cap){
	 	this -> n = cap;
	 	(this -> t).resize(4*n);
	}

	void build(vector<int> &a, int v, int tl, int tr) {
    	if (tl == tr) {
        	t[v] = data(a[tl]);
    	} else {
        	int tm = (tl + tr) / 2;
        	build(a, v*2, tl, tm);
        	build(a, v*2+1, tm+1, tr);
        	t[v] = combine(t[v*2], t[v*2+1]);
    	}
	}
	
	void update(int v, int tl, int tr, int pos, int new_val) {
    	if (tl == tr) {
        	t[v] = data(new_val);
    	} else {
        	int tm = (tl + tr) / 2;
        	if (pos <= tm)
            	update(v*2, tl, tm, pos, new_val);
        	else
            	update(v*2+1, tm+1, tr, pos, new_val);
        	t[v] = combine(t[v*2], t[v*2+1]);
    	}
	}   	
	data query(int v, int tl, int tr, int l, int r) {
    	if (l > r) 
        	return data(0);
    	if (l == tl && r == tr) 
        	return t[v];
    	int tm = (tl + tr) / 2;
    	return combine(query(v*2, tl, tm, l, min(r, tm)), 
                   query(v*2+1, tm+1, tr, max(l, tm+1), r));
	}
};

class LCA {
	public:
    vector<int> height, euler, first, segtree;
    vector<bool> visited;
    int n;

    LCA(vector<vector<int>> &adj, int root = 0) {
        n = adj.size();
        height.resize(n);
        first.resize(n);
        euler.reserve(n * 2);
        visited.assign(n, false);
        dfs(adj, root);
        int m = euler.size();
        segtree.resize(m * 4);
        build(1, 0, m - 1);
    }

    void dfs(vector<vector<int>> &adj, int node, int h = 0) {
        visited[node] = true;
        height[node] = h;
        first[node] = euler.size();
        euler.push_back(node);
        for (auto to : adj[node]) {
            if (!visited[to]) {
                dfs(adj, to, h + 1);
                euler.push_back(node);
            }
        }
    }

    void build(int node, int b, int e) {
        if (b == e) {
            segtree[node] = euler[b];
        } else {
            int mid = (b + e) / 2;
            build(node << 1, b, mid);
            build(node << 1 | 1, mid + 1, e);
            int l = segtree[node << 1], r = segtree[node << 1 | 1];
            segtree[node] = (height[l] < height[r]) ? l : r;
        }
    }

    int query(int node, int b, int e, int L, int R) {
        if (b > R || e < L)
            return -1;
        if (b >= L && e <= R)
            return segtree[node];
        int mid = (b + e) >> 1;

        int left = query(node << 1, b, mid, L, R);
        int right = query(node << 1 | 1, mid + 1, e, L, R);
        if (left == -1) return right;
        if (right == -1) return left;
        return height[left] < height[right] ? left : right;
    }

    int lca(int u, int v) {
        int left = first[u], right = first[v];
        if (left > right)
            swap(left, right);
        return query(1, 0, euler.size() - 1, left, right);
    }
};

class Bit_Tree {
	public :
    vector<int> bit;  
    int n;

    Bit_Tree(int n) {
        this->n = n + 1;
        bit.assign(n + 1, 0);
    }

    Bit_Tree(vector<int> a)
        : Bit_Tree(a.size()) {
        for (size_t i = 0; i < a.size(); i++)
            add(i, a[i]);
    }

    int sum(int idx) {
        int ret = 0;
        for (++idx; idx > 0; idx -= idx & -idx)
            ret += bit[idx];
        return ret;
    }

    int sum(int l, int r) {
        return sum(r) - sum(l - 1);
    }

    void add(int idx, int delta) {
        for (++idx; idx < n; idx += idx & -idx)
            bit[idx] += delta;
    }
};


class TaskB {
 public:
    void solveOne(istream &in, ostream &out) {
        int a,b,c,k;
        in >> a >>b >>c >> k;
        int count_g = 0;
        while(b <= a){
            b*=2;
            count_g+=1;
        }
        int count_b = 0;
        while(c <= b){
            c*=2;
            count_b+=1;
        }
        if(count_b + count_g <= k)out << "Yes" << "\n";
        else out << "No" << "\n";
    }
    
    void solve(std::istream &in, std::ostream &out) {
        int nt = 1;
        //in >> nt;
        for (int it = 0; it < nt; ++it) {
            solveOne(in, out);
        }
    }
};
 
 
signed main() {
  fastio();
  TaskB solver;
  istream& in(cin);
  ostream& out(cout);
  solver.solve(in, out);
  return 0;
}

Compiler output:
Main.java:1: error: illegal character: '#'
#include <bits/stdc++.h>
^
Main.java:1: error: class, interface, enum, or record expected
#include <bits/stdc++.h>
         ^
Main.java:3: error: illegal character: '#'
#define li          long
^
Main.java:3: error: class, interface, enum, or record expected
#define li          long
        ^
Main.java:4: error: illegal character: '#'
#define ll          long long
^
Main.java:5: error: illegal character: '#'
#define ull         unsigned long long
^
Main.java:6: error: illegal character: '#'
#define ff          first
^
Main.java:7: error: illegal character: '#'
#define ss          second
^
Main.java:8: error: illegal character: '#'
#define pii         pair<int,int>
^
Main.java:9: error: illegal character: '#'
#define pli         pair<li,li>
^
Main.java:10: error: illegal character: '#'
#define pll         pair<ll,ll>
^
Main.java:11: error: illegal character: '#'
#define pb          push_back
^
Main.java:12: error: illegal character: '#'
#define fo(i,k,n)   for(int i = k;i<n; i++)
^
Main.java:12: error: class, interface, enum, or record expected
#define fo(i,k,n)   for(int i = k;i<n; i++)
                                  ^
Main.java:12: error: class, interface, enum, or record expected
#define fo(i,k,n)   for(int i = k;i<n; i++)
                                       ^
Main.java:13: error: illegal character: '#'
#define ro(i,k,n)   for(int i = k; i>=n; i--)
^
Main.java:13: error: class, interface, enum, or record expected
#define ro(i,k,n)   for(int i = k; i>=n; i--)
                                   ^
Main.java:13: error: class, interface, enum, or record expected
#define ro(i,k,n)   for(int i = k; i>=n; i--)
                                         ^
Main.java:14: error: illegal character: '#'
#define tc          int t;cin>>t;while(t--)
^
Main.java:14: error: class, interface, enum, or record expected
#define tc          int t;cin>>t;while(t--)
                          ^
Main.java:14: error: class, interface, enum, or record expected
#define tc          int t;cin>>t;while(t--)
                                 ^
Main.java:15: error: illegal character: '#'
#define all(v)      v.begin(),v.end()
^
Main.java:16: error: illegal character: '#'
#define inf         INT_MAX
^
Main.java:17: error: illegal character: '#'
#define ninf        INT_MIN
^
Main.java:18: error: illegal character: '#'
#define v(x)        vector<x>
^
Main.java:19: error: illegal character: '#'
#define int         long long
^
Main.java:20: error: illegal character: '#'
#define ar(x,y)     array<x,y>
^
Main.java:22: error: class, interface, enum, or record expected
const ll mod2 = 1e9+7;
^
Main.java:28: error: not a statement
    ios_base::sync_with_stdio(false);
    ^
Main.java:26: error: unnamed classes are a preview feature and are disabled by default.
void fastio()
^
  (use --enable-preview to enable unnamed classes)
Main.java:28: error: ';' expected
    ios_base::sync_with_stdio(false);
                             ^
Main.java:54: error: class, interface, enum, or record expected
struct dsu{
^
Main.java:56: error: class, interface, enum, or record expected
  dsu(){
  ^
Main.java:58: error: class, interface, enum, or record expected
    (this->sz).clear();
    ^
Main.java:59: error: class, interface, enum, or record expected
  }
  ^
Main.java:62: error: class, interface, enum, or record expected
    sz[x] = 1;
    ^
Main.java:63: error: class, interface, enum, or record expected
  }
  ^
Main.java:66: error: class, interface, enum, or record expected
    return pr[x] = getpar(pr[x]);
    ^
Main.java:67: error: class, interface, enum, or record expected
  }
  ^
Main.java:70: error: class, interface, enum, or record expected
    y = getpar(y);
    ^
Main.java:71: error: class, interface, enum, or record expected
    if(sz[x]<sz[y])swap(x,y);
    ^
Main.java:72: error: class, interface, enum, or record expected
    pr[y] = x;
    ^
Main.java:73: error: class, interface, enum, or record expected
    sz[x]+=sz[y];
    ^
Main.java:74: error: class, interface, enum, or record expected
    sz[y] = 0;
    ^
Main.java:75: error: class, interface, enum, or record expected
  }
  ^
Main.java:79: error: illegal start of type
	public:
	      ^
Main.java:82: error: not a statement
	 	this -> sum = val;
	 	^
Main.java:82: error: ';' expected
	 	this -> sum = val;
	 	    ^
Main.java:83: error: not a statement
   		this -> pref = this -> suff = this -> ans = max(0ll, val);
   		^
Main.java:83: error: ';' expected
   		this -> pref = this -> suff = this -> ans = max(0ll, val);
   		    ^
Main.java:83: error: ';' expected
   		this -> pref = this -> suff = this -> ans = max(0ll, val);
   		                   ^
Main.java:83: error: ';' expected
   		this -> pref = this -> suff = this -> ans = max(0ll, val);
   		                                  ^
Main.java:83: error: ')' or ',' expected
   		this -> pref = this -> suff = this -> ans = max(0ll, val);
   		                                                  ^
Main.java:83: error: ';' expected
   		this -> pref = this -> suff = this -> ans = max(0ll, val);
   		                                                   ^
Main.java:83: error: not a statement
   		this -> pref = this -> suff = this -> ans = max(0ll, val);
   		                                                     ^
Main.java:83: error: ';' expected
   		this -> pref = this -> suff = this -> ans = max(0ll, val);
   		                                                        ^
Main.java:96: error: '{' expected
class Seg_Tree : public data {
              ^
Main.java:96: error: class, interface, enum, or record expected
class Seg_Tree : public data {
                        ^
Main.java:97: error: class, interface, enum, or record expected
	public :
	       ^
Main.java:100: error: class, interface, enum, or record expected
	Seg_Tree(int cap){
	^
Main.java:102: error: class, interface, enum, or record expected
	 	(this -> t).resize(4*n);
	 	^
Main.java:103: error: class, interface, enum, or record expected
	}
	^
Main.java:108: error: class, interface, enum, or record expected
    	} else {
    	^
Main.java:110: error: class, interface, enum, or record expected
        	build(a, v*2, tl, tm);
        	^
Main.java:111: error: class, interface, enum, or record expected
        	build(a, v*2+1, tm+1, tr);
        	^
Main.java:112: error: class, interface, enum, or record expected
        	t[v] = combine(t[v*2], t[v*2+1]);
        	^
Main.java:113: error: class, interface, enum, or record expected
    	}
    	^
Main.java:119: error: class, interface, enum, or record expected
    	} else {
    	^
Main.java:121: error: class, interface, enum, or record expected
        	if (pos <= tm)
        	^
Main.java:123: error: class, interface, enum, or record expected
        	else
        	^
Main.java:125: error: class, interface, enum, or record expected
        	t[v] = combine(t[v*2], t[v*2+1]);
        	^
Main.java:126: error: class, interface, enum, or record expected
    	}
    	^
Main.java:131: error: class, interface, enum, or record expected
    	if (l == tl && r == tr) 
    	^
Main.java:134: error: class, interface, enum, or record expected
    	return combine(query(v*2, tl, tm, l, min(r, tm)), 
    	^
Main.java:136: error: class, interface, enum, or record expected
	}
	^
Main.java:140: error: illegal start of type
	public:
	      ^
Main.java:145: error: <identifier> expected
    LCA(vector<vector<int>> &adj, int root = 0) {
                           ^
Main.java:145: error: ';' expected
    LCA(vector<vector<int>> &adj, int root = 0) {
                                              ^
Main.java:157: error: <identifier> expected
    void dfs(vector<vector<int>> &adj, int node, int h = 0) {
                                ^
Main.java:157: error: <identifier> expected
    void dfs(vector<vector<int>> &adj, int node, int h = 0) {
                                                ^
Main.java:157: error: ';' expected
    void dfs(vector<vector<int>> &adj, int node, int h = 0) {
                                                          ^
Main.java:205: error: illegal start of type
	public :
	       ^
Main.java:210: error: not a statement
        this->n = n + 1;
        ^
Main.java:210: error: ';' expected
        this->n = n + 1;
            ^
Main.java:214: error: ';' expected
    Bit_Tree(vector<int> a)
                           ^
Main.java:239: error: illegal start of type
 public:
       ^
Main.java:240: error: <identifier> expected
    void solveOne(istream &in, ostream &out) {
                         ^
Main.java:242: error: not a statement
        in >> a >>b >>c >> k;
                        ^
Main.java:253: error: not a statement
        if(count_b + count_g <= k)out << "Yes" << "\n";
                                               ^
Main.java:254: error: not a statement
        else out << "No" << "\n";
                         ^
Main.java:257: error: <identifier> expected
    void solve(std::istream &in, std::ostream &out) {
                  ^
Main.java:270: error: not a statement
  istream& in(cin);
         ^
Main.java:271: error: not a statement
  ostream& out(cout);
         ^
93 errors