akhauriyash/Code-Regression huggingface dataset:
#include<bits/stdc++.h>
using namespace std;
#define ll long long
#define lvector vector<ll> 
#define P pair<ll,ll>
#define ALL(a) (a).begin(),(a).end()
#define YESNO(i) if((i)) puts("YES");else puts("NO");
#define YesNo(i) if((i)) puts("Yes");else puts("No");
#define yesno(i) if((i)) puts("yes");else puts("no");
#define rep(i,n) for(ll (i)=0; (i)<(n); ++(i))
#define print(a) cout << (a) << endl

int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  ll a,b;cin>>a>>b;
  YesNo(a==b);
  return 0;
}

Measured memory_bytes: 256
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace std;
using namespace __gnu_pbds;
#define int long long
#define endl '\n'
#define pb push_back
#define fi first
#define se second
#define all(c) (c).begin(),(c).end()
typedef long long ll;
typedef long double ld;
typedef pair<int, int> pii;
typedef vector<int> vi;

template <typename T>
using ordered_set = tree<T, null_type, less<T>, rb_tree_tag, tree_order_statistics_node_update>;

#define TRACE
#ifndef ONLINE_JUDGE
#define trace(...) __f(#__VA_ARGS__, __VA_ARGS__)
template <typename Arg1>
void __f(const char* name, Arg1&& arg1){
	cerr << name << " : " << arg1 << endl;
}
template <typename Arg1, typename... Args>
void __f(const char* names, Arg1&& arg1, Args&&... args){
	const char* comma = strchr(names + 1, ',');cerr.write(names, comma - names) << " : " << arg1<<" | ";__f(comma+1, args...);
}
#else
#define trace(...)
#endif

const ll inf = 2e18;
const int mod = 1e9 + 7;
const int N = 2e5 + 10;

signed main() {
	ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);

	int n;
	cin >> n;
	map<int, int> m;
	for(int i = 2; i * i <= n; i++) {
		if(n % i == 0) {
			while(n % i == 0) {
				n /= i;
				m[i]++;
			}
		}
	}
	if(n > 1) {
		m[n]++;
	}
	int ans = 0;
	for(auto it : m) {
		int cur = 0;
		for(int j = 1; ; j++) {
			cur += j;
			if(cur > it.se) {
				ans += j - 1;
				break;
			}
		}
	}
	cout << ans;

	return 0;
}

Measured memory_bytes: 3648
#include <bits/stdc++.h>
using namespace std;
#define _GLIBCXX_DEBUG
#define rep(i, n) for (int i = 0; i < (int)(n); i++)

int main(){
    int n, m, x;
    cin >> n >> m >> x;
    int left = 0, right = 0;
    vector<int> a(m);
    rep(i, m){
        cin >> a.at(i);
        a.at(i)>x?right++:left++;
    }
    cout << min(right, left) << endl;
    return 0;
}

Measured memory_bytes: 256
import sys
fin = sys.stdin.readline


def initialize_int(adj, s):
    """
    assume that all vertex in {0, 1, 2, ..., N - 1}
    """
    N = len(adj)
    MAX_NUM = float('inf')
    d = [MAX_NUM] * N
    d[s] = 0
    parent = [None] * N
    return d, parent


def relax(d, w, source_v, target_v, parent):
    new_cost = d[source_v] + w[source_v][target_v]
    if new_cost < d[target_v]:
        d[target_v] = new_cost
        parent[target_v] = source_v


# Even if a negative weight exists, bellman-ford can find shortest paths.
# it also detects negative cycles,
# but not all edges that consist the negative cycles is stored.
# time complexity: O(VE + (V^2))
def bellman_ford(adj, w, s):
    d, parent = initialize_int(adj, s)
    # calculate shortest paths
    for _ in range(len(adj)):
        for vertex in range(len(adj)):
            for neighbor in adj[vertex]:
                relax(d, w, vertex, neighbor, parent)

    # detects negative cycles if exist
    negative_cycle_edges = set()
    for vertex in range(len(adj)):
        for neighbor in adj[vertex]:
            if d[neighbor] > d[vertex] + w[vertex][neighbor]:
                negative_cycle_edges.add((vertex, neighbor))
    return d, parent, negative_cycle_edges


N, M = [int(elem) for elem in fin().split()]
adj = [[] for _ in range(N)]
w = [[None] * N for _ in range(N)]

for _ in range(M):
    a, b, c = [int(elem) for elem in fin().split()]
    a -= 1
    b -= 1
    c *= -1
    adj[a].append(b)
    w[a][b] = c

d, parent, negative_cycle_edges = bellman_ford(adj, w, 0)
if len(negative_cycle_edges) > 0:
    # see if there's a path from 0 to this edge via DFS
    stack = [0]
    visited = set()
    visited.add(0)
    reachable_edges = set()
    while stack:
        source = stack.pop()
        for neighbor in adj[source]:
            if (source, neighbor) in negative_cycle_edges:
                reachable_edges.add((source, neighbor))
            if neighbor not in visited:
                visited.add(neighbor)
                stack.append(neighbor)
    # see if there is a path to N - 1
    for _, target in reachable_edges:
        stack = [target]
        visited = set()
        visited.add(target)
        while stack:
            source = stack.pop()
            for neighbor in adj[source]:
                if neighbor == N - 1:
                    print("inf")
                    exit(0)
                if neighbor not in visited:
                    visited.add(neighbor)
                    stack.append(neighbor)
    else:
        print(-d[N - 1])
else:
    print(-d[N - 1])



Measured memory_bytes: 55644
import std.stdio, std.string, std.conv, std.algorithm, std.array, std.math, std.range;
void main(){
	auto n = readln.chomp.to!real;
	auto x = readln.split.map!(to!real);
	auto y = readln.split.map!(to!real);
	real a = zip(x,y).map!(s => (s[0]-s[1]).abs).sum;
	real b = zip(x,y).map!(s => (s[0]-s[1]).abs^^2).sum^^(1/2.0);
	real c = zip(x,y).map!(s => (s[0]-s[1]).abs^^3).sum^^(1/3.0);
	real d = zip(x,y).map!(s => (s[0]-s[1]).abs).reduce!(max);
	writefln("%.6f",a);
	writefln("%.6f",b);
	writefln("%.6f",c);
	writefln("%.6f",d);
}

Measured memory_bytes: 2668
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
#define _GLIBCXX_DEBUG
#define rep(i, a, b) for(int i = a; i < b; i++)
#define ALL(v) v.begin(), v.end()

int main(){
    string s;
    cin>>s;
    sort(s.begin(),s.end());
    if(s[0]==s[1]&&s[2]==s[3]&&s[0]!=s[2])
    cout<<"Yes"<<endl;
    else
    cout<<"No"<<endl;
}

Measured memory_bytes: 256
S = input()

leng = len(S)
count = 0
if leng % 2 == 0:
  S1 = S[:int(leng/2)]
  S2 = S[int(leng/2):]
  for i in range(int(leng/2)):
    if S1[i] == S2[int(leng/2)-1-i]:
      count += 1
  print(int(leng/2)-count)
else:
  S1 = S[:int(leng/2)]
  S2 = S[int(leng/2)+1:]
  for i in range(int(leng/2)):
    if S1[i] == S2[int(leng/2)-1-i]:
      count += 1
  print(int(leng/2)-count)


Measured memory_bytes: 3064
#include <iostream>
#include <string>
#include <stack>
#include <queue>
#include <vector>
#include <algorithm>
#include <cmath>

using namespace std;

#define loop(i,a,b) for(int i=(a);i<int(b);i++)
#define rep(i,b) loop(i,0,b)
#define all(c) (c).begin(), (c).end()
double const eps = 1e-8;

int f(double x){
    if (x + eps >= 1.1){
        return 'A';
    }
    if (x + eps >= 0.6){
        return 'B';
    }
    if (x + eps >= 0.2){
        return 'C';
    }
    return 'D';
}

int main(){
    double L, R;
    int ans[256][2] = {};
    while (cin >> L >> R){
        ans[f(L)][0]++;
        ans[f(R)][1]++;
    }
    rep(i, 4){
        cout << ans["ABCD"[i]][0] << " " << ans["ABCD"[i]][1] << endl;
    }
}

Measured memory_bytes: 1228
#include <bits/stdc++.h>
#define REP(i, n) for (long long i = 0; i < (long long)n; i++)
//#define _GLIBCXX_DEBUG
using namespace std;
using ll = long long;
using Pi = pair<int, int>;
using Pl = pair<ll, ll>;
using Vl = vector<ll>;
using vi = vector<int>;
using Graph = vector<vi>;

int main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  // std::cout << std::fixed << std::setprecision(15); //"for float-base
  // problem"
  ll N, M, K;
  cin >> N >> M >> K;
  Vl A(N), B(M);
  REP(i, N) cin >> A.at(i);
  REP(j, M) cin >> B.at(j);
  Vl C(N + 1), D(M + 1);
  REP(i, N) C.at(i + 1) = C.at(i) + A.at(i);
  REP(i, M) D.at(i + 1) = D.at(i) + B.at(i);

  ll maxl = 0;
  for (ll i = 0; i <= N && C.at(i) <= K; i++) {
    ll nowtime = K - C.at(i);
    ll count = upper_bound(D.begin(), D.end(), nowtime) - D.begin() - 1;
    maxl = max(maxl, i + count);
    /*    printf("j = %lld: time = %lld: count = %lld: maxl = %lld\n", i,
       nowtime, count, maxl);
           */
  }

  cout << maxl << endl;
}

Measured memory_bytes: 9508
from fractions import gcd



a, b, c, d = map(int, input().split())
cd_gcd = gcd(c, d)
cd_lcm = c*d // cd_gcd
b_div_d = b // d
a_div_d = a // d
if a % d == 0:
    b_div_d += 1
b_div_c = b // c
a_div_c = a // c
if a % c == 0:
    b_div_c += 1
b_div_c_d = b // cd_lcm
a_div_c_d = a // cd_lcm
if a % cd_lcm == 0:
    b_div_c_d += 1
hoshugo_num = b_div_d - a_div_d + b_div_c - a_div_c - (b_div_c_d - a_div_c_d)
print(int(b - a + 1 - hoshugo_num))

Measured memory_bytes: 63980
#import<atcoder/all>
#define f(i)printf("%d ",i);
#define g(x)f(size(x))for(auto i:x)
int u,v;main(){std::cin>>u>>v;atcoder::scc_graph G(u);for(;std::cin>>u>>v;)G.add_edge(u,v);g(G.scc()){g(i)f(i)}}

Measured memory_bytes: 40056
S = input()
def main():
  if S[0] != "A":
    print("WA")
    exit()
  head = S[:2]
  if head in ("C"):
    print("WA")
    exit()
  tail = S[-1:]
  if tail in ("C"):
    print("WA")
    exit()
  
  sub = S[2:]
  sub = sub[:-1]
  if sub.count("C") != 1:
    print("WA")
    exit()
  
  for x in S[1:]:
    if x !="C":
      if x.isupper():
        print("WA")
        exit()
  print("AC")
  
if __name__ == "__main__":
  main()
  

Measured memory_bytes: 3064
#include <bits/stdc++.h>
#define fi first
#define se second

typedef long long ll;
typedef std::pair < int, int > pr;
const int N = 200005; 
using std::cin;
using std::cout;

inline void up(int &x, int y) { x < y ? x = y : 0; }
inline void down(int &x, int y) { x > y ? x = y : 0; }

int n, k, x, a[N], tot, ans;
std::vector < int > v;
int main() {
    std::ios::sync_with_stdio(false), std::cin.tie(0);
    cin >> n >> k;
    for (int i = 1; i <= n; ++i) {
        cin >> x;
        if (a[x] == 0) ++tot;
        ++a[x];
    }
    for (int i = 1; i <= 200000; ++i) 
        if (a[i]) v.push_back(a[i]);
    std::sort(v.begin(), v.end());
    for (int i = 0; i < tot - k; ++i) ans += v[i];
    cout << ans << '\n'; 
    return 0;
}



Measured memory_bytes: 4964
N = int(input())
S = list(input())


def check(a1, a2):
    ans = [a1, a2]
    for i, s in enumerate(S + [S[0]]):
        if i == 0:
            continue

        if ans[i] == 0:
            if s == "o":
                ans.append(ans[i - 1])
            else:
                ans.append(ans[i - 1] ^ 1)
        else:
            if s == "x":
                ans.append(ans[i - 1])
            else:
                ans.append(ans[i - 1] ^ 1)

    if ans[:2] != ans[-2:]:
        return None
    else:
        return ans[:-2]


# 0: S / 1:W
for a1 in range(2):
    for a2 in range(2):
        ans = check(a1, a2)
        if ans is not None:
            print("".join(map(lambda x: "S" if x == 0 else "W", ans)))
            exit()


print(-1)


Measured memory_bytes: 5612
use proconio::input;

fn main() {
    input! {
        s: String,
        t: String,
    }

    let s: Vec<char> = s.chars().collect();
    let t: Vec<char> = t.chars().collect();
    let len = s.len();
    let mut ans = 0;
    for i in 0 .. len {
        if s[i] != t[i] { ans += 1 };
    }

    println!("{}", ans);
}


Measured memory_bytes: 4456
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;

int main() {
    int n;
    cin >> n;
    n = n % 10;
    int a[] = {2,4,5,7,9};
    int b[] = {0,1,6,8};
    for (auto k:a) {
        if (n == k) {
            cout << "hon" << endl;
            return 0;
        }
    }
    for (auto k:b) {
        if (n == k) {
            cout << "pon" << endl;
            return 0;
        }
    }
    cout << "bon" << endl;
    return 0;
}

Measured memory_bytes: 3632
#include <iostream>
#include <iomanip>
#include <string>
#include <vector>
#include <algorithm>
#include <numeric>
#include <utility>
#include <cmath>
#include <tuple>
#include <queue>
#include <bitset>
#include <set>
#include <map>
#include <list>
#include <cassert>

using namespace std;


void solve(long long N, std::vector<long long> a){
  sort(a.begin(), a.end());
  vector<long long> ac(3, 0);
  vector<long long> ab(3, 0);
  int j = 0;
  long long t;
  if (a[0] == 0) {
    t = a[0];
    for (int i = 0; i < N; i++) {
      if (a[i] == t) {
        ac[j]++;
      } else {
        t = a[i];
        j++;
        if (j >= 2) {
          std::cout << "No" << std::endl;
          return;
        }
        ac[j]++;
      }
    }
    if (ac[0]*2 == ac[1] || ac[1] == 0) {
      std::cout << "Yes" << std::endl;
    } else {
      std::cout << "No" << std::endl;
    }
  } else {
    t = a[0];
    ab[0] = t;
    for (int i = 0; i < N; i++) {
      if (a[i] == t) {
        ac[j]++;
      } else {
        j++;
        if (j >= 3) {
          std::cout << "No" << std::endl;
          return;
        }
        ac[j]++;
        t = a[i];
        ab[j] = t;
      }
    }
    if (ac[0] == ac[1] && ac[1] == ac[2] && ((ab[0] ^ ab[1]) == ab[2])) {
      std::cout << "Yes" << std::endl;
    } else {
      std::cout << "No" << std::endl;
    }
  }
}

int main(){
  long long N;
  scanf("%lld",&N);
  std::vector<long long> a(N);
  for(int i = 0 ; i < N ; i++){
    scanf("%lld",&a[i]);
  }
  solve(N, std::move(a));
  return 0;
}


Measured memory_bytes: 1024
#include <iostream>
#include<queue>
#include<stack>
#include<vector>
#include<set>
#include<map>
#include<algorithm>
#include<cstring>
#include<string>
#include<cassert>
#include<cmath>
#include<climits>
#include<iomanip>
#include<bitset>
#include<unordered_map>

using namespace std;

#define rep(i,m,n) for(int (i)=(int)(m);(i)<(int)(n);(i)++)
#define rep2(i,m,n) for(int (i)=(int)(n)-1;(i)>=(int)(m);(i)--)
#define REP(i,n) rep(i,0,n)
#define FOR(i,c) for(decltype((c).begin())i=(c).begin();i!=(c).end();++i)
#define ll long long
#define ull unsigned long long
#define all(hoge) (hoge).begin(),(hoge).end()
#define en '\n'
typedef pair<ll, ll> P;
constexpr long long INF = 1LL << 60;
constexpr int INF_INT = 1 << 25;
constexpr long long MOD = 998244353;
typedef vector<ll> Array;
typedef vector<Array> Matrix;
template <class T> using vec = vector<T>;
template <class T> using vvec = vector<vec<T>>;


template<class T> inline bool chmin(T& a, T b) {
	if (a > b) {
		a = b;
		return true;
	}
	return false;
}
template<class T> inline bool chmax(T& a, T b) {
	if (a < b) {
		a = b;
		return true;
	}
	return false;
}

struct Edge {
	ll to, cap, rev;
	Edge(ll _to, ll _cap, ll _rev) {
		to = _to; cap = _cap; rev = _rev;
	}
};
typedef vector<Edge> Edges;
typedef vector<Edges> Graph;

void add_edge(Graph& G, ll from, ll to, ll cap, bool revFlag, ll revCap) {
	G[from].push_back(Edge(to, cap, (ll)G[to].size()));
	if (revFlag)G[to].push_back(Edge(from, revCap, (ll)G[from].size() - 1));
}


ll dfs(Graph& g, ll v,Array& c) {
	bool flag = true;
	for (auto e : g[v]) {
		if (c[e.to] == -1) {
			c[e.to] = !c[v];
			if (!dfs(g, e.to, c)) flag = false;
		}
		else {
			if (c[e.to] == c[v]) flag = false;
		}
	}
	return flag;
}

void solve() {
	ll r, g, b, n;
	cin >> r >> g >> b >> n;
	ll con = 0;
	for (int i = 0; i * r <= n;i++) {
		for (int j = 0; i * r + j * g <= n;j++) {
			ll k = n - i*r - j*g;
			if (k%b==0) {
				con++;
			}
		}
	}
	cout << con << en;
}

int main() {
	ios::sync_with_stdio(false);
	cin.tie(0);
	cout.tie(0);

	solve();
	//int t; cin >> t; REP(i, t) solve();

	return 0;
}


Measured memory_bytes: 256
# frozen_string_literal: true

# induce sort (internal routine)
def sa_is_induce(s, ls, sum_l, sum_s, lms)
  n = s.size
  sa = [-1]*n

  buf = *sum_s # deep copy
  lms.each{ |lms|
    if lms != n then
      sa[buf[s[lms]]] = lms
      buf[s[lms]] += 1
    end
  }

  buf = *sum_l # deep copy
  sa[buf[s[-1]]] = n-1
  buf[s[-1]] += 1
  sa.each{ |v|
    if v>=1 && !ls[v-1] then
      sa[buf[s[v-1]]] = v-1
      buf[s[v-1]] += 1
    end
  }

  buf = *sum_l # deep copy
  sa.reverse_each{ |v|
    if v>=1 && ls[v-1] then
      buf[s[v-1]+1] -= 1
      sa[buf[s[v-1]+1]] = v-1
    end
  }

  return sa
end

# SA-IS (internal routine)
def sa_is(s, upper)
  n = s.size

  return [] if n == 0
  return [0] if n == 1

  ls = [false]*n
  (n-2).downto(0){ |i|
    ls[i] = s[i]==s[i+1] ? ls[i+1] : s[i]<s[i+1]
  }

  sum_l = [0]*(upper+1)
  sum_s = [0]*(upper+1)
  n.times{ |i|
    if ls[i] then
      sum_l[s[i]+1] += 1
    else
      sum_s[s[i]] += 1
    end
  }
  0.upto(upper){ |i|
    sum_s[i] += sum_l[i]
    sum_l[i+1] += sum_s[i] if i<upper
  }

  lms = (1 ... n).select{ |i| !ls[i-1] && ls[i] }
  m=lms.size
  lms_map = [-1]*(n+1)
  lms.each_with_index{ |lms, id| lms_map[lms] = id }

  sa = sa_is_induce(s, ls, sum_l, sum_s, lms)

  return sa if m == 0

  sorted_lms = sa.select{ |sa| lms_map[sa] != -1 }
  rec_s = [0]*m
  rec_upper = 0
  rec_s[lms_map[sorted_lms[0]]] = 0
  1.upto(m-1){ |i|
    l, r = sorted_lms[i-1, 2]
    end_l = lms[lms_map[l]+1]||n
    end_r = lms[lms_map[r]+1]||n
    same = true
    if end_l-l != end_r-r then
      same = false
    else
      while l < end_l do
        break if s[l] != s[r]
        l+=1
        r+=1
      end
      same = false if l==n || s[l]!=s[r]
    end
    rec_upper += 1 if not same
    rec_s[lms_map[sorted_lms[i]]] = rec_upper
  }

  sa_is(rec_s, rec_upper).each_with_index{ |rec_sa, id|
    sorted_lms[id] = lms[rec_sa]
  }

  return sa_is_induce(s, ls, sum_l, sum_s, sorted_lms)
end

# suffix array for array of integers or string
def suffix_array(s, upper = nil)
  if not upper then
  	case s
  	when Array
      # compression
      n = s.size
      idx = (0 ... n).sort_by{ |i| s[i] }
      t = [0]*n
      upper = 0
      t[idx[0]] = 0
      1.upto(n-1){ |i|
        upper += 1 if s[idx[i-1]] != s[idx[i]]
        t[idx[i]] = upper
      }
      s = t
    when String
      upper = 255
      s = s.bytes
    end
  end
  return sa_is(s, upper)
end

# frozen_string_literal: true

# lcp array for array of integers or string
def lcp_array(s, sa)
  s = s.bytes if s === String

  n = s.size
  rnk = [0]*n
  sa.each_with_index{ |sa, id|
    rnk[sa] = id
  }
  
  lcp = [0]*(n-1)
  h = 0
  n.times{ |i|
    h -= 1 if h > 0
    next if rnk[i] == 0
    j = sa[rnk[i]-1]
    h += 1 while j+h<n && i+h<n && s[j+h]==s[i+h]
    lcp[rnk[i]-1] = h
  }
  return lcp
end

s = gets.chomp
lcp = lcp_array(s, suffix_array(s))
ans = s.size*(s.size+1)/2
lcp.each{ |lcp| ans -= lcp }
puts ans


Measured memory_bytes: 63440
#include <iostream>
#include <iomanip>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <cstdlib>

using namespace std;


int main(){

  int n;
  cin >> n;
  int * x = new int[n];
  
  for(int i=0;i<n;i++){
    cin >> x[i];
  }

  int c=0;
  for(int i=0;i<n;i++){
    int mini = i;
    for(int j=i;j<n;j++){
      if(x[j] < x[mini]){
        mini = j;
      }
    }
    if(i != mini){
      c++;
      int tmp = x[i];
      x[i] = x[mini];
      x[mini] = tmp;
    }
  }

  for(int i=0;i<n;i++){
    cout << x[i];
    if(i==n-1) cout << endl;
    else cout << " ";
  }
  cout << c << endl;


}



Measured memory_bytes: 3104
while 1:
    (H,W) = [int(i) for i in input().split()]
    if H==W==0:
        break
    for i in range(H):
        for j in range(W):
            if (i+j)%2==0: print('#',end="")
            else: print('.',end="")
        print('')
    print('')


Measured memory_bytes: 7020
// https://qiita.com/tanakh/items/0ba42c7ca36cd29d0ac8
macro_rules! input {
    (source = $s:expr, $($r:tt)*) => {
        let mut iter = $s.split_whitespace();
        input_inner!{iter, $($r)*}
    };
    ($($r:tt)*) => {
        let s = {
            use std::io::Read;
            let mut s = String::new();
            std::io::stdin().read_to_string(&mut s).unwrap();
            s
        };
        let mut iter = s.split_whitespace();
        input_inner!{iter, $($r)*}
    };
}

macro_rules! input_inner {
    ($iter:expr) => {};
    ($iter:expr, ) => {};

    ($iter:expr, $var:ident : $t:tt $($r:tt)*) => {
        let $var = read_value!($iter, $t);
        input_inner!{$iter $($r)*}
    };
}

macro_rules! read_value {
    ($iter:expr, ( $($t:tt),* )) => {
        ( $(read_value!($iter, $t)),* )
    };

    ($iter:expr, [ $t:tt ; $len:expr ]) => {
        (0..$len).map(|_| read_value!($iter, $t)).collect::<Vec<_>>()
    };

    ($iter:expr, chars) => {
        read_value!($iter, String).chars().collect::<Vec<char>>()
    };

    ($iter:expr, usize1) => {
        read_value!($iter, usize) - 1
    };

    ($iter:expr, $t:ty) => {
        $iter.next().unwrap().parse::<$t>().expect("Parse error")
    };
}

fn main() {
    input! {
        x: i32, t: i32
    }
    let ans = if x - t > 0 { x - t } else { 0 };
    println!("{}", ans);
}


Measured memory_bytes: 4352
#include<bits/stdc++.h>

int main(){
    using namespace std;
    unsigned long Q;
    cin >> Q;
    constexpr auto M{205891132094649UL};
    const auto& calc = [](auto a, auto b, auto c, auto d){
        auto u{b}, p{M};
        while(p /= 3)if(a / p + (M + 1 - a / p) % 3 <= c / p && b / p % 3 == 1){
            u = b / (3 * p) * 3 * p + 2 * p;
            break;
        }
        return c - a + min(u - b + max(u, d) - min(u, d), b + d - 2 * (b / (3 * p) * 3 * p + p - 1));
    };
    for(unsigned long _{0}, a, b, c, d; _ < Q; ++_){
        cin >> a >> b >> c >> d;
        if(--a > --c)swap(a, c), swap(b, d);
        if(--b > --d){
            b = M - b - 1;
            d = M - d - 1;
        }
        cout << max(calc(a, b, c, d), calc(b, a, d, c)) << endl;
    }
    return 0;
}

Measured memory_bytes: 384
#include <bits/stdc++.h>
#define ll long long
using namespace std;


int main()
{

    ll n,sum=0;
    cin>>n;
    int a[n];
    for(ll i=0;i<n;i++)
    {
        cin>>a[i];
    }
    for(ll i=1;i<n;i++)
    {
       if(a[i]<a[i-1]) {sum+=abs(a[i]-a[i-1]);a[i]+=abs(a[i]-a[i-1]);}
    }
    cout<<sum;
    return 0;
}


Measured memory_bytes: 4368
#include<stdio.h>
#include<math.h>
double x[4],y[4],eps=1e-6;
int f(int *a,int *b){
  int i;
  for(i=0;i<2;i++)b[i]-=a[i];
  double l=hypot(b[0],b[1]);
  double c=acos((a[2]-b[2])/l);//printf("%lf %lf\n",l,c);
  if(a[2]>l+b[2]+eps||b[2]>l+a[2]+eps)return 0;
  //printf("%lf " ,(b[0]*cos( c)-b[1]*sin( c))*a[2]/l+a[0]     );
  x[0]=(b[0]*cos( c)-b[1]*sin( c))*a[2]/l+a[0];
  //printf("%lf " ,(b[0]*sin( c)+b[1]*cos( c))*a[2]/l+a[1]     );
  y[0]=(b[0]*sin( c)+b[1]*cos( c))*a[2]/l+a[1];
  //printf("%lf " ,(b[0]*cos( c)-b[1]*sin( c))*b[2]/l+a[0]+b[0]);
  //printf("%lf\n",(b[0]*sin( c)+b[1]*cos( c))*b[2]/l+a[1]+b[1]);
  if(a[2]+eps>l+b[2]||b[2]+eps>l+a[2])return 1;
  //printf("%lf " ,(b[0]*cos(-c)-b[1]*sin(-c))*a[2]/l+a[0]     );
  x[1]=(b[0]*cos(-c)-b[1]*sin(-c))*a[2]/l+a[0];
  //printf("%lf " ,(b[0]*sin(-c)+b[1]*cos(-c))*a[2]/l+a[1]     );
  y[1]=(b[0]*sin(-c)+b[1]*cos(-c))*a[2]/l+a[1];
  //printf("%lf " ,(b[0]*cos(-c)-b[1]*sin(-c))*b[2]/l+a[0]+b[0]);
  //printf("%lf\n",(b[0]*sin(-c)+b[1]*cos(-c))*b[2]/l+a[1]+b[1]);
  if(l+eps<a[2]+b[2])return 2;
  c=acos((a[2]+b[2])/l);//printf("%lf %lf\n",l,c);
  //printf("%lf " ,(b[0]*cos( c)-b[1]*sin( c))*a[2]/l+a[0]     );
  x[2]=(b[0]*cos( c)-b[1]*sin( c))*a[2]/l+a[0];
  //printf("%lf " ,(b[0]*sin( c)+b[1]*cos( c))*a[2]/l+a[1]     );
  y[2]=(b[0]*sin( c)+b[1]*cos( c))*a[2]/l+a[1];
  //printf("%lf " ,(b[0]*cos( c)-b[1]*sin( c))*b[2]/l+a[0]+b[0]);
  //printf("%lf\n",(b[0]*sin( c)+b[1]*cos( c))*b[2]/l+a[1]+b[1]);
  if(l<a[2]+b[2]+eps)return 3;
  //printf("%lf " ,(b[0]*cos(-c)-b[1]*sin(-c))*a[2]/l+a[0]     );
  x[3]=(b[0]*cos(-c)-b[1]*sin(-c))*a[2]/l+a[0];
  //printf("%lf " ,(b[0]*sin(-c)+b[1]*cos(-c))*a[2]/l+a[1]     );
  y[3]=(b[0]*sin(-c)+b[1]*cos(-c))*a[2]/l+a[1];
  //printf("%lf " ,(b[0]*cos(-c)-b[1]*sin(-c))*b[2]/l+a[0]+b[0]);
  //printf("%lf\n",(b[0]*sin(-c)+b[1]*cos(-c))*b[2]/l+a[1]+b[1]);
  return 4;
}

int main(){
  int p[2][3],i,j,n,r[4];//xyr
  for(i=0;i<6;i++)scanf("%d",&p[i/3][i%3]);
  n=f(p[0],p[1]);
  for(i=0;i<n;i++){
    for(j=i;j;j--){
      if(x[r[j-1]]+eps<x[i]||(fabs(x[r[j-1]]-x[i])<eps&&y[r[j-1]]+eps<y[i]))break;
      r[j]=r[j-1];
    }
    r[j]=i;
  }
  for(i=0;i<n;i++)printf("%.10lf %.10lf\n",x[r[i]],y[r[i]]);
  return 0;
}



Measured memory_bytes: 2104
#!/usr/bin/env python
# -*- coding: utf-8 -*-

import sys
sys.setrecursionlimit(10**7)
from pprint import pprint as pp
from pprint import pformat as pf

import math
#from sortedcontainers import SortedList, SortedDict, SortedSet # no in atcoder
import bisect


if __name__ == '__main__':
    types = set()
    n = int(input())
    for i in range(n):
        s = input()
        types.add(s)
        #print('types') # debug
        #print(types) # debug
    print(len(types))


    #print('\33[32m' + 'end' + '\033[0m') # debug


Measured memory_bytes: 94884
#include <iostream>
#include <vector>

using namespace std;

int main()
{
    int n, m;
    cin >> n >> m;

    vector<int> roads(n, 0);
    for (int i = 0; i < m; i++) {
        int a, b;
        cin >> a >> b;
        roads[a-1]++;
        roads[b-1]++;
    }

    for (int i = 0; i < n; i++) {
        cout << roads[i] << endl;
    }
}

Measured memory_bytes: 256
#include <cstdio>
#include <cstring>
#include <cstdlib>
#include <cmath>
#include <ctime>
#include <cassert>
#include <string>
#include <algorithm>
#include <vector>
#include <queue>
#include <stack>
#include <functional>
#include <iostream>
#include <map>
#include <set>
#include <cassert>
#include <string.h>
#include <iomanip>

using namespace std;

int main()
{
	int A, B;
	cin >> A >> B;
	
	if (A >= 13) cout <<B<<endl;
	else if(A>=6 && A<=12) cout <<B/2 <<endl;
	else if(A<=5) cout<<0 <<endl;
	
	
	
	
	
	
	
	return 0;
}



Measured memory_bytes: 256
#include <algorithm>
#include <bitset>
#include <complex>
#include <deque>
#include <exception>
#include <fstream>
#include <functional>
#include <iomanip>
#include <ios>
#include <iosfwd>
#include <iostream>
#include <istream>
#include <iterator>
#include <limits>
#include <list>
#include <locale>
#include <map>
#include <memory>
#include <new>
#include <numeric>
#include <ostream>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <stdexcept>
#include <streambuf>
#include <string>
#include <typeinfo>
#include <utility>
#include <valarray>
#include <vector>
#include <climits>
#include <cstring>

#define rep(i, m, n) for(int i=int(m);i<int(n);i++)
#define all(c) begin(c),end(c)

template<typename T1, typename T2>
inline void chmin(T1 &a, T2 b) { if (a > b) a = b; }

template<typename T1, typename T2>
inline void chmax(T1 &a, T2 b) { if (a < b) a = b; }

typedef long long int ll;
using ll = long long int;
using ull = long long unsigned int;
using Int = long long int;
using namespace std;
#define INF (1 << 30) - 1
#define INFl (ll)5e15
#define DEBUG 0
#define dump(x)  cerr << #x << " = " << (x) << endl
#define MOD 1000000007


//edit
class Solve {
public:
    Int N, M;
    vector<Int> X;
    vector<vector<Int>> Y;

    Int func(Int m) {
        if ((m + m) % M == 0) {
            Int ret = static_cast<Int>(Y[m].size() / 2);
            return ret;
        }

        Int ret = 0ll;
        Int n = M - m;
        if (Y[m].size() == Y[n].size()) {
            return static_cast<Int>(Y[m].size());
        } else if (Y[m].size() < Y[n].size()) {
            ret += Y[m].size();
            map<Int, Int> neri;
            for (int i = 0; i < Y[n].size(); ++i) {
                neri[Y[n][i]]++;
            }

            Int tmp = 0;
            for (auto e : neri) {
                tmp += e.second / 2;
            }
            ret += min<Int>(tmp, static_cast<const Int &>((Y[n].size() - Y[m].size()) / 2));
        } else {
            swap(n, m);
            ret += Y[m].size();
            map<Int, Int> neri;
            for (int i = 0; i < Y[n].size(); ++i) {
                neri[Y[n][i]]++;
            }

            Int tmp = 0;
            for (auto e : neri) {
                tmp += e.second / 2;
            }
            ret += min<Int>(tmp, static_cast<const Int &>((Y[n].size() - Y[m].size()) / 2));
        }

        return ret;
    }

    void solve() {
        cin >> N >> M;
        X.resize(N);
        for (auto &x : X) cin >> x;

        Y.resize(M);
        for (int i = 0; i < X.size(); ++i) {
            Y[X[i] % M].push_back(X[i]);
        }
        for (int i = 0; i < M; ++i) {
            sort(all(Y[i]));
        }

        Int ans = 0;
        for (int i = 0; 2 * i <= M; ++i) {
            ans += func(i);
        }

        cout << ans << endl;

    }
};


int main() {
    cin.tie(0);
    ios::sync_with_stdio(false);
    cout << fixed << setprecision(10);

    Solve().solve();


    return 0;
}


Measured memory_bytes: 6528
#include <bits/stdc++.h>
using namespace std;

int main () {
  
  int N;
  cin >> N;
  int min = 100000;
  
  for (int x = 0; x <= N; x++) {
    
    int p = x;
    int q = N - p;
    int counter = 0;
    
    // pを6進法で表す
    
    if (p > 0) {
      while (p > 0) {
        int r = p % 6;
        counter += r;
        p /= 6;
      }
    }
    
    // yを9進法で表す
    
    if (q > 0) {
      while (q > 0) {
        int r = q % 9;
        counter += r;
        q /= 9;
      }
    }
    
    if (min > counter) min = counter;
    
  }
  
  cout << min << endl;  
  
}

Measured memory_bytes: 256
#include<bits/stdc++.h>
using namespace std;
int main()

{
    int n, k, x, y;
    cin>>n>>k>>x>>y;
    long long int ans;
    if(n>=k)
        ans = x*k + (n-k)*y;
    else ans = n*x;
    cout<<ans<<endl;
    return 0;
}


Measured memory_bytes: 3616
// Problem : B - Beautiful Strings
// Contest : AtCoder - AtCoder Beginner Contest 044
// URL : https://atcoder.jp/contests/abc044/tasks/abc044_b
// Memory Limit : 256 MB
// Time Limit : 2000 ms
// Powered by CP Editor (https://github.com/cpeditor/cpeditor)

#include <bits/stdc++.h>

#define spc ' '
#define endl '\n'

using namespace std;


int main(){
	ios_base :: sync_with_stdio(0); cin.tie(0); cout.tie(0);
	vector<int> v(26);
	string s;
	cin >> s;
	int n = s.size();
	for(int i=0; i<n; i++){
	    v[s[i]-'a']++;
	}
	for(int i=0; i<26; i++){
	    if(v[i]&1){
	        cout<< "No";
	        return 0;
	    }
	}
	cout << "Yes";
	return 0;
}

Measured memory_bytes: 256
#include<bits/stdc++.h>
using namespace std;
int main(){
  int n, m, lMax, rMin;
  cin>>n>>m;
  int L[m+1], R[m+1];
  for(int i=0;i<m;i++){
  	int l, r;
    cin>>l>>r;
    L[i]=l;
    R[i]=r;
  }
  lMax=L[0], rMin=R[0];
  for(int i=1;i<m;i++){
  	if(lMax<L[i]) lMax = L[i];
    if(rMin>R[i]) rMin = R[i];
  }
  if(lMax>rMin) cout<<0<<endl;
  else cout<<rMin-lMax+1<<endl;
      
}

Measured memory_bytes: 1024
#include<cstdio>
#include<cstring>
#include<algorithm>
#include<iostream>
#include<string>
#include<vector>
#include<stack>
#include<bitset>
#include<cstdlib>
#include<cmath>
#include<set>
#include<list>
#include<deque>
#include<map>
#include<queue>
using namespace std;
typedef long long ll;
const double PI = acos(-1.0);
const double eps = 1e-6;
const int INF = 1000000000;
const int mod = 1e9+7;
const int maxn = 2e5+5;
ll n,m;
int dp[maxn];
int a[10][10];
int main() {
	
	cin>>n;
	int cnt = 0;
	for(int i=1;i<=9;i++){
		for(int j=1;j<=9;j++){
			if(i==j&&i<=n) a[i][j]++;
			if((j*10+i)<=n) a[i][j]++;
			for(int l=0;l<=9;l++){
				int num = j*100+l*10+i;
				if(num<=n) a[i][j]++;
				else break;
			}
			for(int l=0;l<=99;l++){
				int num = j*1000+l*10+i;
				if(num<=n) a[i][j]++;
				else break;
			}
			for(int l=0;l<=999;l++){
				int num = j*10000+l*10+i;
				if(num<=n) a[i][j]++;
				else break;
			}
			for(int l=0;l<=9999;l++){
				int num = j*100000+l*10+i;
				if(num<=n) a[i][j]++;
				else break;
			}
		}
	}
	//dp[1] = 1;
	for(int i=1;i<=9;i++){
		dp[i] = dp[i-1]+a[i][i];
	//	cout<<i<<endl;
	//	cout<<a[i][i]<<endl;
	}
		
	for(int i=10;i<=n;i++){
		if(i%10==0){
			dp[i] = dp[i-1];
			continue;
		}
		int x = i%10,y;
		int t = i;
		while(t){
			y = t%10;
			t/=10;
		}
		dp[i] = dp[i-1]+a[y][x];
	//	cout<<x<<" "<<y<<endl;
	//	cout<<a[y][x]<<endl;
		
	}
	cout<<dp[n]<<endl;
}



Measured memory_bytes: 1024
#include <bits/stdc++.h>
#define REP(i,n) for(int i=0;i<(n);++i)
using namespace std;
typedef long long ll;

int main() {
  int N,A,B,C;
  cin >> N >> A >> B >> C;
  vector<int> L(N,0);
  REP(i,N) cin >> L[i];

  int la,lb,lc;
  int mi = 1 << 30;
  for(ll i=0 ;i<(1<<(N*2)); ++i ) {
    int mp = 0;
    la = lb = lc = 0;
    REP(j,N) {
      int t = (i >> (j*2)) & 3;
      if ( t == 1 ) {
        if ( la != 0 ) mp += 10;
        la += L[j];
      } else if ( t == 2 ) {
        if ( lb != 0 ) mp += 10;
        lb += L[j];
      } else if ( t == 3 ) {
        if ( lc != 0 ) mp += 10;
        lc += L[j];
      }
    }
    if ( (la == 0) || (lb == 0) || (lc == 0) ) continue;
    mp += abs(A-la)+abs(B-lb)+abs(C-lc);
    mi = min(mi, mp);
  }
  cout << mi << endl;

  return 0;
}


Measured memory_bytes: 384
#include <stdio.h>

int main() {

int al[30] = {0};
char b[2000]= {0};
int i,j,n;

i=0;

while( scanf("%c",&b[i]) != EOF) {

if (b[i] >= 'A' && 'Z' >= b[i] ) {
n = b[i] - 'A';
al[n] += 1;

} else if(b[i] >=  'a' && b[i] <= 'z' ) {
n = b[i] - 'a';
al[n] += 1;
}
i=i+1;
}

for(j=97; j<=122; j++) {
n = j - 'a';
printf("%c : %d\n",j,al[n]);
}

return 0;

}



Measured memory_bytes: 2112
#include<stdio.h>
#include<stdlib.h>

int main(void){
    int N;

    scanf("%d", &N);

    int *C, *V;
    C = (int*)malloc(N * sizeof(int));
    V = (int*)malloc(N * sizeof(int));

    int i;
    int sum = 0;
    for(i=0; i<N; i++) {
        scanf("%d", &V[i]);
    }
    for(i=0; i<N; i++) {
        int temp;
        scanf("%d", &C[i]);
        if((temp = V[i] - C[i]) > 0) {
            sum += temp;
        }
    }

    printf("%d\n", sum);
    free(C);
    free(V);
}

Measured memory_bytes: 128
/*   _/                _/                 _/_/_/   _/
  _/_/_/_/   _/_/   _/_/_/_/   _/_/    _/       _/_/
   _/     _/    _/   _/     _/    _/  _/_/_/     _/
  _/     _/    _/   _/     _/    _/  _/    _/   _/
   _/_/   _/_/       _/_/   _/_/      _/_/     _/ */
#include<iostream>
#include<algorithm>
#include<cmath>
#include<iomanip>
#include<set>
#include<map>
#include<queue>
#include<vector>
using namespace std;
using ll=long long;
const int MOD=1e9+7;
const double pi=3.14159265358979323846;
const int inf=1e9;
const ll INF=1e18;
using P=pair<int,int>;
int dx[4]={1,0,-1,0},dy[4]={0,1,0,-1};
int main() {
  cin.tie(0),cout.tie(0);
  ios::sync_with_stdio(false);
  int n,a[100005]={},ans=1,u=0,d=0;
  cin >> n;
  for(int i=0; i<n; i++) {
    cin >> a[i];
  }
  for(int i=0; i<n-1; i++) {
    if(a[i]<a[i+1]) {
      u=1;
    }
    else if(a[i]>a[i+1]) {
      d=1;
    }
    if(u&&d) {
      ans++;
      u=d=0;
    }
  }
  cout << ans << endl;
}

Measured memory_bytes: 640
#include<bits/stdc++.h>
using namespace std;

#define rep(i,n) for(int i=0;i<n;i++)
#define REP(i,s,n) for(int i=(s);i<=(n);i++)
#define repr(i,n) for(int i=n-1;i>=0;i--)
#define REPR(i,s,n) for(int i=(s);i>=(n);i--)
#define all(a) (a).begin(),(a).end()
#define rall(a) (a).rbegin(),(a).rend()
#define Eunique(v) v.erase(unique(all(v)),v.end())
#define Eback(s) s.erase(s.end()-1,s.end())
#define rev(v) reverse(all(v))
#define minvec(v) *min_element(all(v))
#define maxvec(v) *max_element(all(v))
#define sumvec(v) accumulate(all(v),0)
#define mapmax(v) v.rbegin()->first
#define mapmin(v) v.begin()->first
#define pb push_back
#define pf push_front
#define mod 1000000007
#define m_p make_pair
#define DOUBLE fixed << setprecision(15)
#define OK puts("OK")
#define OK1 puts("OK1")
#define OK2 puts("OK2")
#define SIZE(s) (int)s.size()
#define INF ((1LL<<62)-(1LL<<31))
#define zero(x,n) setw(x) << setfill('0') << n

typedef long long ll;

typedef vector<int> vi;
typedef vector<long long> vll;
typedef vector<double> vd;
typedef vector<char> vc;
typedef vector<string> vs;

typedef vector<vi> vvi;
typedef vector<vll> vvll;
typedef pair<ll,ll> pll;
typedef pair<int,int> pii;
typedef vector<pair<int,int>> vpii;
typedef vector<pair<ll,ll>> vpll;

const double pi = acos(-1.0);

template<class A, class B>
ostream& operator<<(ostream& ost, const pair<A, B>&p) {
	ost << "{" << p.first << ", " << p.second << "} ";
	return ost;
}

template<class T>
ostream& operator<<(ostream& ost, const vector<T>&v) {
	ost << "{";
	for (int i = 0; i<(int)v.size(); i++) {
		if (i)ost << " ";
		ost << v[i];
	}
	ost << "} \n";
	return ost;
}

template<class A, class B>
ostream& operator<<(ostream& ost, const map<A, B>&v) {
	ost << "{";
	for (auto p:v) {
		ost << "{" << p.first << ", " << p.second << "} ";
	}
	ost << "} ";
	return ost;
}

template<class T>
inline bool chmax(T& a, T b){if(a<b){a=b;return true;} return false;}

template<class T>
inline bool chmin(T& a, T b){if(a>b){a=b;return true;} return false;}

void YES(bool b) {cout << (b?"YES\n":"NO\n");}
void Yes(bool b) {cout << (b?"Yes\n":"No\n");}
void yes(bool b) {cout << (b?"yes\n":"no\n");}
void Yay(bool b) {cout << (b?"Yay!\n":":(\n");}

ll gcd(ll x, ll y) {return __gcd(x,y);}
ll lcm(ll x, ll y) {return x/__gcd(x,y)*y;}

int main()
{
	ll a,b,c;
	cin >> a >> b >> c;
	if(c-a-b<=0) cout << "No\n";
	else Yes(4*a*b<(c-a-b)*(c-a-b));
	return 0;
}


Measured memory_bytes: 256
s = list(input()[::-1])
t = list(input()[::-1])

for shift in range(len(s) - len(t) + 1):
  for i in range(len(t)):
    if s[i + shift] != "?" and s[i + shift] != t[i]:
      break
  else:
    s[shift:shift+len(t)] = t
    print("".join(s[::-1]).replace("?", "a"))
    break
else:
  print("UNRESTORABLE")

Measured memory_bytes: 39696
#include<bits/stdc++.h>

using namespace std;

int main ()
{
    int a[200]={0};
    string s;
    getline(cin,s);
    for(int i=0;i<s.length();i++){
        a[s[i]]++;
        if(a[s[i]]>1) {cout<<"no"<<endl; return 0;}
    }
    cout<<"yes"<<endl;
    return 0;
}


Measured memory_bytes: 256
#include<iostream>
#include<vector>
#include<string>
#include<algorithm>
#include<tuple>
#include<map>
#include<queue>
#include<math.h>
#include<numeric>
#include<iomanip>
#define rep(i, n) rep2(i,0,n)
#define rep2(i, s, n) for (int i = (s); i < (int)(n); i++)
#define PI acos(-1);
typedef long long ll;
using namespace std;
const int MOD = 1000000007;
//scanf("%d", &a); '\n'; cout << fixed << setprecision(10);

int main() {
	int s, w;
	cin >> s >> w;
	cout << (s > w ? "safe" : "unsafe");
}

Measured memory_bytes: 3616
#include <iostream>
#include <string>
#include <vector>
#include <deque>
#include <queue>
#include <algorithm>
#include <set>
#include <map>
#include <bitset>
#include <cmath>
#define vv(a, b, c, d) vector<vector<d> >(a, vector<d>(b, c))
#define vvi std::vector<std::vector<int> >
#define vvl std::vector<std::vector<ll> >
#define MODs 1000000007;
typedef long long int ll;
typedef long double ld;
using namespace std;
#include <iomanip>

int main(int argc, char const *argv[]) {
  ld N;
  ld ans = 0;
  std::cin >> N;
  int n = N;
  if(n%2==0) ans = 0.5;
  else ans = ((N+1)/2)/N;
  std::cout << fixed << setprecision(20) << ans << '\n';
  return 0;
}


Measured memory_bytes: 888
#include<bits/stdc++.h>
using namespace std;
using ll  = long long;
using vl  = vector<ll>;
using vi  = vector<int>;
#define _GLIBCXX_DEBUG
#define IO_STREAM cin.tie(0);ios::sync_with_stdio(false)
#define all(x) x.begin(),x.end()
#define rep(i,sta,end) for(int i=sta;i<end;++i)
#define lcm(a,b) (a)/__gcd((a),(b))*(b)
#define pb push_back
const ll INF = 1000000000000000;
const ll MOD = 1000000007;
const double PI = acos(-1);
//||
#define DBG(a,b,c,d) //cout<<a<<" "<<b<<" "<<c<<" "<<d<<" "<<endl
//DBG("","","","");

signed main(){
	IO_STREAM;
	int N;	cin>>N;
	string S,T;	cin>>S>>T;
	string ans;
	rep(i,0,N){
		ans.pb(S[i]);
		ans.pb(T[i]);
	}
	cout<<ans<<endl;
	return 0;
}


Measured memory_bytes: 3620
#include <bits/stdc++.h>
using namespace std;

int main() {
  int N;
  string S;
  cin >> N >> S;

  int length = S.size();
  string replaced = S;
  int ascii;
  for (int i = 0; i < length; i++) {
    ascii = static_cast<int>(S.at(i) + N);
    if (ascii > static_cast<int>('Z')) {
      ascii-= static_cast<int>('Z' - 'A' + 1);
    }
    replaced.at(i) = static_cast<char>(ascii);
  }
  cout << replaced << endl;
}


Measured memory_bytes: 256
#include <iostream>
#define rep(i,n) for(int i=0; i<(int)(n); i++)

using namespace std;
typedef long long LL;
const LL mod=1e9+7;
const int Max_Num=200010;

LL modinv(LL x){
	LL m=mod, u=1, v=0;
	while(m){
		LL t=x/m;
		x-=t*m; swap(x,m);
		u-=t*v; swap(u,v);
	}
	u%=mod;
	if(u<0) u+=mod;
	return u;
}

int main(){
  LL n, k;
  cin >> n >> k;
  LL F[Max_Num], Finv[Max_Num];
  F[0]=1;
  rep(i,Max_Num-1){
  	F[i+1]=F[i]*(i+1);
  	F[i+1]%=mod;
  }
  rep(i,Max_Num) Finv[i]=modinv(F[i]);
  LL dp[Max_Num]={0};
  dp[0]=1;
  for(LL i=1; i<=min(k,n-1); i++){
    dp[i]=dp[i-1]+(F[n]*Finv[i]%mod*Finv[n-i]%mod)
    *(F[n-1]*Finv[n-i-1]%mod*Finv[i]%mod);
    dp[i]%=mod;
  }
  if(k<=n-1) cout << dp[k] << endl;
  else cout << dp[n-1] << endl;

  return 0;
}


Measured memory_bytes: 4992
#pragma GCC optimize("Ofast")
#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")

#include <iostream>
#include <fstream>
#include <cstdio>
#include <cstring>
#include <cmath>
#include <algorithm>
#include <vector>
#include <string>
#include <queue>
#include <deque>
#include <stack>
#include <set>
#include <map>
#include <bitset>
#include <sstream>
#include <iomanip>

using namespace std;

typedef long long ll;
typedef vector <int> vi;
typedef vector <vector <int>> vii;
typedef vector <long long> vll;
typedef vector <string> vs;
typedef vector <char> vc;
typedef set <int> si;
typedef set <string> ss;
typedef queue <int> qi;
typedef queue <long long> qll;
typedef queue <string> qs;
typedef queue <char> qc;
typedef struct board board;
typedef pair <int, int> pi;
typedef pair <long long, long long> pll;
typedef pair <int, pair<int, int>> pii;

#define eb emplace_back
#define ppb pop_back
#define clr(a) a.clear()
#define F first
#define S second
#define mkp make_pair

#define sz(x) (int)(x).size()
#define all(x) (x).begin(), (x).end()

#define left(x) x * 2
#define right(x) x * 2 + 1

#define meme(a, b, c) fill(a + 1, a + 1 + b, c)

#define max(a, b) (a > b ? a : b)
#define min(a, b) (a > b ? b : a)
#define abs(a) (a > 0? a : -(a))

#define move(s) s += "#"

#define eprintf(...) fprintf(stderr, __VA_ARGS__);

template <typename T>
void printArr(const T * arr, int s, int fn) {
    for (int i = s; i <= fn; ++ i) cout << arr[i] << " ";
    cout << '\n';
}

template <typename T>
long long minArr(const T * arr, int s, int fn) {
    ll res = 1e16 + 1;
    for (int i = s; i <= fn; ++ i) {
        res = min(res, arr[i]);
    }
    return res;
}

template <typename T>
void printVec(const T * arr) {
    for (int i = 0; i < sz(arr); ++ i) cout << arr[i] << " ";
    cout << '\n';
}

template <class T>
bool uax(T&a, const T& b) {
    if (a < b) {
        a = b;
        return true;
    }
    return false;
}

template <class T>
bool uin (T&a, const T& b) {
    if (a > b) {
        a = b;
        return true;
    }
    return false;
}

void to_pray() {
    ios_base::sync_with_stdio(0);
    cin.tie(0);
    cout.tie(0);
    cerr << "Ready\n";
}

const int N = 1e5 + 10;
const int NN = 1e3 + 10;
const int NNN = 2e3 + 9;
const int MOD = 1e9 + 7;
const int INF = 1e9 + 7;
const ll LLINF = 1e12 + 7;
const int EPS = 1e-9 - 8;
const int vN = 2e4 + 10;
const int sz = (1 << 22) - 1;
const double PI = acos(-1);

int main () {
    to_pray();

    int n;
    cin >> n;

    int mx = 0;
    int sum = 0;

    for (int i = 1; i <= n; ++ i) {
        int x;
        cin >> x;
        mx = max(mx, x);
        sum += x;
    }

    cout << (sum - mx > mx?"Yes":"No");

    //eprintf("%.18lf seconds\n", (double)clock() / CLOCKS_PER_SEC);

    cout << '\n';
    
    return 0;
}

Measured memory_bytes: 256
#include<bits/stdc++.h>
using namespace std;

#define rep(i,n) for(int i=0;i<n;i++)
#define REP(i,s,n) for(int i=(s);i<=(n);i++)
#define repr(i,n) for(int i=n-1;i>=0;i--)
#define REPR(i,s,n) for(int i=(s);i>=(n);i--)
#define all(a) (a).begin(),(a).end()
#define rall(a) (a).rbegin(),(a).rend()
#define Eunique(v) v.erase(unique(all(v)),v.end())
#define Eback(s) s.erase(s.end()-1,s.end())
#define rev(v) reverse(all(v))

typedef long long ll;

typedef vector<int> vi;
typedef vector<vi> vvi;
typedef vector<long long> vll;
typedef vector<vll> vvll;
typedef vector<double> vd;
typedef vector<vd> vvd;
typedef vector<char> vc;
typedef vector<vc> vvc;
typedef vector<bool> vb;
typedef vector<vb> vvb;
typedef vector<string> vs;

typedef pair<ll,ll> pll;
typedef pair<int,int> pii;
typedef vector<pair<int,int>> vpii;
typedef vector<pair<ll,ll>> vpll;

const double pi = acos(-1.0);
const int mod=1000000007;
const int mod2=998244353;

ll powmod(ll a,ll b){ll c=1; while(b>0){ if(b&1){ c=a*c%mod; } a=a*a%mod; b>>=1; } return c;}
ll gcd(ll x, ll y) {return __gcd(x,y);}
ll lcm(ll x, ll y) {return x/__gcd(x,y)*y;}



int main()
{
	int A,B;cin>>A>>B;
    if(A>0&&A<=9&&B>0&&B<=9)cout<<A*B<<endl;
    else cout<<-1<<endl;


}

 
    

Measured memory_bytes: 256
#include <bits/stdc++.h>

using namespace std;

#define PB(x)	push_back(x)
#define ALL(x)	(x).begin(), (x).end()
#define ALLR(x)	(x).rbegin(), (x).rend()
#define MP(x)	make_pair(x)

#define debug(_x)		cerr << #_x << '=' << _x << endl;
#define debug2(_x, _y)	cerr << #_x << '=' << _x << ' ' << #_y << '=' << _y << endl;
#define debugn(_a)		cerr << #_a << ": "; for (const auto _x: _a) cerr << _x << ' '; cerr << endl;

#define FAST_IO ios::sync_with_stdio(false); cin.tie(0)

#define int long long int

typedef pair<int, int> ii;
typedef vector<int> vi;
typedef vector<vi> vvi;
typedef vector<ii> vii;
typedef vector<string> vs;
typedef unsigned long long ull;

const int INF = LONG_LONG_MAX >> 1;
const int NINF = LONG_LONG_MIN;
const int mmod = 100000000000ll;

int32_t main() {
	FAST_IO;
	
	string s;
	cin >> s;
	
	for (char c: s) cout << 'x';
	cout << endl;
}
// g++ -Wall -Wextra -Wshadow -fsanitize=undefined 


Measured memory_bytes: 256
#include <bits/stdc++.h>
using namespace std;

using ll = long long;

constexpr ll M = 1e9 + 7;
ll dp2[256][256][256];
int sz[256];

int dfs(int v, vector<vector<int>>& g, vector<vector<ll>>& dp) {
    if(g[v].size() == 0) {
        dp[v][1] = 1;
        return sz[v] = 1;
    }

    int sum = 1;
    for(auto ch : g[v]) {
        sum += dfs(ch, g, dp);
    }

    vector<vector<ll>> tmp(g[v].size() + 1, vector<ll>(sum));
    tmp[0][0] = 1;
    for(int i = 0; i < (int)g[v].size(); ++i) {
        int ch = g[v][i];
        for(int l = 0; l < sum; ++l) {
            for(int j = 0; j <= l; ++j) {
                for(int k = 1; k <= sz[ch]; ++k) {
                    (tmp[i + 1][l] += (tmp[i][j] * dp[ch][k] % M) * dp2[j][k][l]) %= M;
                }
            }
        }
    }
    for(int i = 0; i < sum; ++i) {
        dp[v][i + 1] = tmp[g[v].size()][i];
    }
    //cout << "v: " << v << ",  (vnum, res) : " << "(" << sum << ", " << res << ")" << endl;
    return sz[v] = sum;
}

int main() {
    for(int i = 0; i < 201; ++i) {
        dp2[i][0][i] = 1;
        dp2[0][i][i] = 1;
    }
    for(int k = 1; k < 201; ++k) {
        for(int i = 1; i < 201; ++i) {
            for(int j = 1; j < 201; ++j) {
                (dp2[i][j][k] += dp2[i - 1][j - 1][k - 1] + dp2[i - 1][j][k - 1] + dp2[i][j - 1][k - 1]) %= M;
            }
        }
    }

    int N;
    cin >> N;
    vector<vector<int>> g(N);
    vector<bool> in(N);
    for(int i = 0; i < N - 1; ++i) {
        int a, b;
        cin >> a >> b;
        g[a].push_back(b);
        in[b] = true;
    }
    int root = -1;
    for(int i = 0; i < N; ++i) {
        if(!in[i]) {
            root = i;
            break;
        }
    }
    vector<vector<ll>> dp(N + 1, vector<ll>(N + 1));
    dfs(root, g, dp);

    ll res = 0;
    for(int i = 0; i <= N; ++i) {
        (res += dp[root][i]) %= M;
    }
    cout << res << endl;
}


Measured memory_bytes: 84500
#include <bits/stdc++.h>

#define rep(i, n) for(int i = 0; i < (int)(n); i++)
using namespace std;
typedef long long ll;

int main(){
    ll W, H ,x, y;
    cin >> W >> H >> x >> y;

    cout << W * H / 2.0;
    cout << " ";
    
    if(W == 2 * x && H == 2 * y){
        cout << 1 << endl;
    }else{
        cout << 0 << endl;
    }
}

Measured memory_bytes: 256
#define others
#ifdef poj
#include <iostream>
#include <cstring>
#include <cmath>
#include <cstdio>
#include <algorithm>
#include <vector>
#include <string>
#include <map>
#include <set>
#endif // poj
#ifdef others
#include <bits/stdc++.h>
#endif // others
//#define file
#define all(x) x.begin(), x.end()
using namespace std;
const double eps = 1e-8;
const double pi = acos(-1.0);
int dcmp(double x) {
    if(fabs(x)<=eps) return 0;
    return (x>0)?1:-1;
};
typedef long long LL;
typedef unsigned long long ULL;
void umax(int &a, int b) {
    a = max(a, b);
}
void umin(int &a, int b) {
    a = min(a, b);
}

void file() {
    freopen("a.in", "r", stdin);
//    freopen("1.txt", "w", stdout);
}

int main() {
//    file();
    int n, a, b;
    scanf("%d%d%d", &n, &a, &b);
    if((b - a) % 2 == 0) {
        puts("Alice");
    } else {
        puts("Borys");
    }
    return 0;
}

/*
624564646487
664212112111
*/


Measured memory_bytes: 256