#include<bits/stdc++.h>
using namespace std;
#define sz       200000
#define ll       long long
#define pb       push_back
#define pi       2*acos(0.0)
#define f        first
#define s        second
#define mod      1000000007
#define fastio   {ios_base::sync_with_stdio(false);cin.tie(NULL);}
#define test     ll t; cin>>t; while(t--)
const int N = 1e6;

bool prime[N+5];
void primenire()
{
    int i, j;
    prime[0]=true;
    prime[1]=true;
    for(i=4; i<=N; i+=2)
    {
        prime[i]=true;
    }
    for(i=3; i*i<=N; i+=2)
    {
        if(!prime[i])
        {
            for(j=i*i; j<=N; j+=2*i)
            {
                prime[j]=true;
            }
        }
    }
}

vector<int> node[100003];
int vis[100003];
int dis[100003];
ll cnt,ans;
void dfs(int x)
{
    cnt++;
    vis[x]=1;
    for(int i=0;i<node[x].size();i++)
    {
        int tmp=node[x][i];
        if(!vis[tmp])
        {
            dfs(tmp);
        }
    }
}
ll big_mod(ll base, ll power)
{
    if(power == 0)return 1;
    int h = big_mod(base, power / 2);
    h = (h * h) % mod;
    if(power % 2 )h = (h * base) % mod;
    return h;

}

int main()
{
double a,b;
cin>>a>>b;
double p = (a*1.0/100*1.0);
double pp = (p*1.0*b);
cout<<pp<<endl;
}

#include <iostream>
#include <string>
#include <vector>
#include <deque>
#include <queue>
#include <algorithm>
#include <iomanip>
#include <set>
#include <map>
#include <bitset>
#include <cmath>
#include <functional>

using namespace std;

#define REP(i,n) for(ll (i) = (0);(i) < (n);++i)
#define REV(i,n) for(ll (i) = (n) - 1;(i) >= 0;--i)
#define PB push_back
#define EB emplace_back
#define MP make_pair
#define FI first
#define SE second
#define SHOW1d(v,n) {REP(WW,n)cerr << v[WW] << ' ';cerr << endl;}
#define SHOW2d(v,WW,HH) {REP(W_,WW){REP(H_,HH)cerr << v[W_][H_] << ' ';cerr << endl;}}
#define ALL(v) v.begin(),v.end()
#define Decimal fixed<<setprecision(20)
#define INF 1000000000
#define LLINF 1000000000000000000LL
#define MOD 998244353

typedef long long ll;
typedef pair<ll,ll> P;

struct UF {
	vector<int> par; // 親のインデックスを記憶する配列
	vector<int> sz; // サイズを記憶する。
	// 初期化
	UF(int n):par(n),sz(n){
		for(int i = 0; i < n; i++){
			par[i] = i;sz[i] = 1;
		}
	}
	// 親を求める
	int find(int x) {
		if (par[x] == x) return x;
		else return par[x] = find(par[x]);
	}
	// xとyの属する集合を併合
	void unite(int x, int y) {
		x = find(x); y = find(y);
		if (x == y) return;
		if(sz[x] > sz[y])swap(x, y);
		par[x] = y;
		sz[y] += sz[x];
		// マージデクはここでやる(x -> y)
	}
	// xとyが同じ集合ならtrue
	bool same(int x, int y) { return find(x) == find(y); }
	// 素の集合のサイズを求める
	int size(int n){return sz[find(n)];}
};

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

  ll n;cin >> n;
  UF uf(n);
  REP(i, n) {
    ll a;cin >> a;a--;
    uf.unite(i, a);
  }

  ll cou = 0;
  REP(i, n)if(uf.find(i) == i)cou++;
  ll ans = 1;
  REP(i, cou)ans = ans * 2 % MOD;
  cout << (ans + MOD - 1) % MOD << endl;

	return 0;
}


// https://atcoder.jp/contests/abc180/tasks/abc180_e

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

#define REP(i,n)   for(int i=0; i<(int)(n); i++)
#define FOR(i,b,e) for(int i=(b); i<=(int)(e); i++)
#define DEBUG 1
#if DEBUG
  #define _GLIBCXX_DEBUG
  #define DUMP(a) REP(_i, a.size()) cout << a[_i] << (_i + 1 == a.size() ? "\n" : " ")
  #define DUMP2D(b) REP(_j, b.size()) DUMP(b[_j]); cout << endl
#else
  #define DUMP(a)
  #define DUMP2D(b)
#endif

const int N_MAX = 17;
const int X_I_MAX = 1e6;
const int Y_I_MAX = 1e6;
const int Z_I_MAX = 1e6;
const int INF = 1e9;

int N;
vector<int> X;
vector<int> Y;
vector<int> Z;

int S;
vector<vector<int>> d;
vector<vector<int>> dp;

int main() {
  cin >> N;
  X = vector<int>(N);
  Y = vector<int>(N);
  Z = vector<int>(N);
  REP(i, N) cin >> X[i] >> Y[i] >> Z[i];

  d = vector<vector<int>>(N, vector<int>(N));
  REP(v, N) REP(u, N) {
    d[v][u] = abs(X[u] - X[v]) + abs(Y[u] - Y[v]) + max(0, Z[u] - Z[v]);
  }

  S = 1 << N;
  dp = vector<vector<int>>(S, vector<int>(N, INF));
  dp[S - 1][0] = 0;

  for (int s = S - 2; s >= 0; s--) {
    REP(v, N) REP(u, N) if (!(s >> u & 1)){
      dp[s][v] = min(dp[s][v], d[v][u] + dp[s | 1 << u][u]);
    }
    REP(v, N) REP(u, N) if (s >> u & 1){
      dp[s][v] = min(dp[s][v], d[v][u] + dp[s][u]);
    }
  }

  int ans = dp[0][0];
  cout << ans << endl;
}

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

template <class A, class B> bool cmin(A& a, B b) { return a > b && (a = b, true); }
template <class A, class B> bool cmax(A& a, B b) { return a < b && (a = b, true); }

template <typename T> class Dinic {
public:
  static_assert(std::is_integral<T>::value, "Integral required.");
  struct edge {
    int to;
    T cap;
    int rev;
  };

private:
  const int V;
  T max_cap;
  vector<int> level, iter, que;
  static unsigned long long floor2(unsigned long long v) {
    v = v | (v >> 1), v = v | (v >> 2);
    v = v | (v >> 4), v = v | (v >> 8);
    v = v | (v >> 16), v = v | (v >> 32);
    return v - (v >> 1);
  }
  void bfs(const int s, const T base) {
    fill(level.begin(), level.end(), -1);
    level[s] = 0;
    int qh = 0, qt = 0;
    for (que[qt++] = s; qh < qt;) {
      int v = que[qh++];
      for (edge& e : G[v]) {
        if (level[e.to] < 0 && e.cap >= base) {
          level[e.to] = level[v] + 1;
          que[qt++] = e.to;
        }
      }
    }
  }
  T dfs(const int v, const int t, const T base, const T f) {
    if (v == t) return f;
    T sum = 0;
    for (int& i = iter[v]; i < (int)G[v].size(); i++) {
      edge& e = G[v][i];
      if (e.cap >= base && level[v] < level[e.to]) {
        T d = dfs(e.to, t, base, min(f - sum, e.cap));
        if (d > 0) {
          e.cap -= d;
          G[e.to][e.rev].cap += d;
          sum += d;
          if (f - sum < base) break;
        }
      }
    }
    return sum;
  }

public:
  vector<vector<edge> > G;

  Dinic(const int node_size) : V(node_size), max_cap(0), level(V), iter(V), que(V), G(V) {}
  void add(const int from, const int to, const T cap) {
    G[from].push_back((edge){to, cap, (int)G[to].size()});
    G[to].push_back((edge){from, (T)0, (int)G[from].size() - 1});
    max_cap = max(max_cap, cap);
  }
  T solve(const int s, const int t) {
    T flow = 0;
    for (T base = floor2(max_cap); base >= 1;) {
      bfs(s, base);
      if (level[t] < 0) {
        base >>= 1;
        continue;
      }
      fill(iter.begin(), iter.end(), 0);
      flow += dfs(s, t, base, numeric_limits<T>::max());
    }
    return flow;
  }
};

signed main() {
  cin.tie(nullptr)->sync_with_stdio(false);

  int N;
  cin >> N;
  int MX = N + 4e5 + 2;
  Dinic<int> D(MX);
  for (int i = 0; i < N; i++) {
    D.add(MX - 2, i, 1);
    int a, b;
    cin >> a >> b, a--, b--;
    D.add(i, N + a, 1);
    D.add(i, N + b, 1);
  }
  for (int i = 0; i < 4e5; i++) {
    D.add(N + i, MX - 1, 1);
  }
  cout << D.solve(MX - 2, MX - 1) << '\n';
}


//#include <atcoder/all>
//using namespace atcoder;
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define REP(i, n) for(int i=0; i<n; i++)
#define REPR(i, n) for(int i=n-1; i>=0; i--)
#define FOR(i, m, n) for(int i=m; i<n; i++)
#define ALL(v) v.begin(), v.end()
#define SIZE(x) int(x.size())
#define bit(n) (1LL<<(n))
#define FIX(d) fixed << setprecision(d)
using P = pair<int, int>;
using vvi = vector<vector<int>>;
using vvl = vector<vector<ll>>;
template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return 1; } return 0; }
template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return 1; } return 0; }
const int INF = 2e9;
const ll LINF = (1LL<<60);

int main() {
  ios::sync_with_stdio(false);
  cin.tie(nullptr);
  int n,w; cin >> n >> w;
  vector<int> s(n), t(n), p(n);
  REP(i,n) cin >> s[i] >> t[i] >> p[i];

  vector<ll> sums(2e5+1, 0);
  REP(i,n){
    sums[s[i]] += p[i];
    sums[t[i]] -= p[i];
  }
  REP(i,2e5) sums[i+1] += sums[i];

  REP(i,2e5){
    if(sums[i]>w){
      cout << "No\n";
      return 0;
    }
  }
  cout << "Yes\n";
  return 0;
}

#include<bits/stdc++.h>

using namespace std;
using ll = long long;
const int MT = 200010;

int main()
{
	int N; cin >> N; ll W; cin >> W;
	vector<ll> imos(MT + 1);
	for(int i = 0; i < N; i++) {
		ll s, t, p; cin >> s >> t >> p;
		imos[s] += p;
		imos[t] -= p;
	}
	for(int i = 0; i < MT; i++)imos[i + 1] += imos[i];
	cout << (*max_element(imos.begin(), imos.end()) <= W ? "Yes" : "No") << endl;
}


#include <algorithm>
#include <bitset>
#include <cassert>
#include <cmath>
#include <climits>
#include <cstdlib>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <string>
#include <vector>
#define DEBUG 1
using namespace std;
constexpr int kMod = 1000000007;
typedef long long LL;

pair<int, int> p(LL N) {
  set<LL> v;
  for (LL i = 1; i * i <= N; ++i) {
    if (N % i == 0) {
      v.insert(i);
      v.insert(N/i);
    }
  }
  int cnt_o = 0, cnt_e = 0;
  for (auto i : v) {
    if (i % 2 == 0) ++cnt_e;
    else            ++cnt_o;
  }
  return {cnt_o, cnt_e};
}

template<typename T1, typename T2>
ostream& operator << (ostream& os, const pair<T1, T2>& p){
  os << "{" << p.first << "," << p.second << "} ";
  return os;
}

int main() {
  int T; cin >> T;
  for (int i = 0; i < T; ++i) {
    LL c; cin >> c;
    if (c % 2 == 1) {
      cout << "Odd" << endl;
    } else {
      c /= 2;
      if (c % 2 == 1) cout << "Same" << endl;
      else            cout << "Even" << endl;
    }
  }
}

#include <bits/stdc++.h>

using namespace std;
using ll = long long;

#define debug(x) cerr << #x << " = " << x << endl;
#define all(v) (v).begin(), (v).end()
#define rall(v) (v).rbegin(), (v).rend()
#define MSET(c, v) memset(c, v, sizeof(c))

const ll INF = 1e17;
const int NEGINF = 0xC0C0C0C0;
const int NULO = -1;
const double EPS = 1e-10;
const ll mod = 1e9 + 7;

int dx[] = {0,1,-1,0};
int dy[] = {1,0,0,-1};

const int maxn = 1e3 + 10;

void solveTestCase() {
    ll n;
    cin >> n;
    if(n & 1) {
        cout << "Odd\n";
    } else {
        if(n % 4 == 0) {
            cout << "Even\n";
        } else {
            cout << "Same\n";
        }
    }
}

int main() {
    ios::sync_with_stdio(false);
    int test;

    cin >> test;
    // test = 1;
    while(test--) {
        solveTestCase();
    }
    return 0;
}


#include <iostream>
#include <vector>
#include <string>
#include <algorithm>
#include <cstdio>
#include <cstring>
#include <cmath>
using namespace std;
using ll = long long;

int main() {
    ll n;
    cin >> n;

    double t = (double)(n + 1);
    t = sqrt(2 * t + 0.25) - 0.5;
    int m = 10000;
    ll x = (ll)t + m;

    for (int i = 0; i < m * 2; i++) {
        ll s = x * (x + 1) / 2;
        if (x * (x + 1) / 2 <= n + 1) break;
        x--;
    }

    cout << n + 1 - x << endl;

    return 0;
}

#include <iostream>
#include <cmath>

using namespace std;

int main() {
    long long n;
    cin >> n;
    long long k = (long long)floor(sqrt(2 * n + (long double)2.25) - (long double)0.5);
    long long result = n - k + 1;
    cout << result << endl;
}


#include <bits/stdc++.h>
using namespace std;
#define F first
#define S second
#define R cin>>
#define ll long long
#define ln cout<<'\n'
#define in(a) insert(a)
#define pb(a) push_back(a)
#define pd(a) printf("%.10f\n",a)
#define mem(a) memset(a,0,sizeof(a))
#define all(c) (c).begin(),(c).end()
#define iter(c) __typeof((c).begin())
#define rrep(i,n) for(ll i=(ll)(n)-1;i>=0;i--)
#define REP(i,m,n) for(ll i=(ll)(m);i<(ll)(n);i++)
#define rep(i,n) REP(i,0,n)
#define tr(it,c) for(iter(c) it=(c).begin();it!=(c).end();it++)
ll check(ll n,ll m,ll x,ll y){return x>=0&&x<n&&y>=0&&y<m;}void pr(){ln;}
template<class A,class...B>void pr(const A &a,const B&...b){cout<<a<<(sizeof...(b)?" ":"");pr(b...);}
template<class A>void PR(A a,ll n){rep(i,n)cout<<(i?" ":"")<<a[i];ln;}
const ll MAX=1e9+7,MAXL=1LL<<61,dx[8]={-1,0,1,0,-1,-1,1,1},dy[8]={0,1,0,-1,-1,1,1,-1};
typedef pair<ll,ll> P;

void Main() {
  string s;
  R s;
  vector<ll> a[2];
  rep(i,s.size()) {
    if(s[i]=='o') a[0].pb(i);
    if(s[i]=='x') a[1].pb(i);
  }
  ll ans=0;
  rep(k,10000) {
    ll u[10];
    mem(u);
    if(!k||k<1000) u[0]=1;
    ll x=k;
    while(x) {
      u[x%10]=1;
      x/=10;
    }
    rep(i,a[0].size()) {
      if(!u[a[0][i]]) goto next;
    }
    rep(i,a[1].size()) {
      if(u[a[1][i]]) goto next;
    }
    ans++;
  next:;
  }
  pr(ans);
}

int main(){ios::sync_with_stdio(0);cin.tie(0);Main();return 0;}

#pragma GCC optimize(2)
//#include <bits/stdc++.h>
#include <iostream>
#include <set>
#include <cmath>
#include <cstdio>
#include <algorithm>
#include <cstring>
#include <queue>
#include <vector>
#include <utility>
#include <map>
#define rush()      int T; while(cin>>T) while(T--)
#define ms(a,b)     memset(a,b,sizeof a)
#define lowbit(x)   ((x)&(-x))
#define inf         0x7f7f7f7fll
#define eps         1e-11
#define sd(a)       scanf("%d",&a)
#define sll(a)      scanf("%lld",&a)
#define sll2(a,b)   scanf("%lld%lld",&a,&b)
#define sll3(a,b,c) scanf("%lld%lld%lld",&a,&b,&c)
#define sdd(a,b)    scanf("%d%d",&a,&b)
#define sddd(a,b,c) scanf("%d%d%d",&a,&b,&c)
#define sf(a)       scanf("%lf",&a)
//#define sc(a)       scanf("%c\n",&a)
#define ss(a)       scanf("%s",a)
#define pd(a)       printf("%d\n",a)
#define pdd(a,b)    printf("%d %d\n",a,b)
#define pddd(a,b,c) printf("%d %d %d\n",a,b,c)
#define pll(a)      printf("%lld\n",a)
#define pf(a)       printf("%.1lf\n",a)
#define pc(a)       printf("%c",a)
#define ps(a)       printf("%s\n",a)
#define rep(i,a,b)  for(int i=(a);i<=(b);i++)
#define forn(i,a,b,x)  for(int i=(a);i<=(b);i+=(x))
#define per(i,a,b)  for(int i=(b);i>=(a);i--)
#define pb(a)       push_back(a)
#define mp(a,b)     make_pair(a,b)
#define debug(a)    cout<<#a<<" : "<<a<<" "<<" ; "
#define dbg(a)      cout<<#a<<" : "<<a<<endl
#define show(a,b)   cout<<a<<" :\t"<<b<<"\t*"<<endl
#define IOS         ios::sync_with_stdio(0); cin.tie(0)
#define PAUSE       system("pause")
#define all(x)      x.begin(),x.end()
//#define print(a)    cout<<a<<endl;continue;
#define fr          first
#define sc          second
#define ceils(a,b)  ((a-1ll+b)/(b))
#define floors(a,b) floor(double(a)/double(b))
using namespace std;
//inline void swap(int &x,int &y){x^=y^=x^=y;}
typedef long long ll;
//using ui=unsigned int;
typedef unsigned long long ull;
typedef pair<int,int> pii;
const double pi=acos(-1.0);
const int dx[]={0,1,0,-1};
const int dy[]={1,0,-1,0};
const int limit=5e5;

int read()
{
	int s=0;
	char c=getchar(),lc='+';
	while (c<'0'||'9'<c) lc=c,c=getchar();
	while ('0'<=c&&c<='9') s=s*10+c-'0',c=getchar();
	return lc=='-'?-s:s;
}

void write(int x)
{
	if (x<0) putchar('-'),x=-x;
	if (x<10) putchar(x+'0');
	else write(x/10),putchar(x%10+'0');
}

void print(int x,char c='\n')
{
	write(x);
	putchar(c);
}

ll mod=2147483648;
const int N=3e5+5;

    int n, m, _;
    int i, j, k;
    int a[N];
    int pos[N];
    vector<int> ans;

signed main()
{
    //IOS;
    rush(){
        sd(n);
        rep(i, 1, n) sd(a[i]), pos[a[i]] = i;
        int opt = 1;
        rep(i, 1, n){
            if(i == pos[i]) continue;
            if((pos[i] - 1) % 2 != opt){
                if(pos[i] - 2 >= i){
                    ans.pb(pos[i] - 2);
                    int x = pos[i] - 2, y = pos[i] - 1;
                    swap(pos[a[x]], pos[a[y]]);
                    swap(a[x], a[y]);
                    opt ^= 1;
                }
                else {
                //if(pos[i] == i + 1){
                    ans.pb(i - 1);
                    ans.pb(i);
                    ans.pb(i - 1);
                    ans.pb(i);
                    ans.pb(i - 1);
                    //ans.pb(i);
                    opt ^= 1;
                    int x = pos[i], y = pos[i] - 1;
                    swap(pos[a[x]], pos[a[y]]);
                    swap(a[x], a[y]);
                    continue;
                }
            }
            for(int j = pos[i] - 1; j >= i; j--){
                ans.pb(j);
                int x = j, y = j + 1;
                swap(pos[a[x]], pos[a[y]]);
                swap(a[x], a[y]);
                opt ^= 1;
            }
        }
        pd(ans.size());
        for(auto it : ans) printf("%d ", it);
        puts("");
        ans.clear();
    }
    //PAUSE;
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
#define ll long long
const ll mod=1e9+7;
const ll INF=4e18;
const int inf=1e9;
const double pi=acos(-1);
ll n, ans;

ll cek(ll pos, ll pjg){
	return pjg*(2*pos+(pjg-1))/2;
}

int main() {
	ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0);
	cin >> n;
	for(int len=1;len<=2000000;++len){
		ll l=1, r=n;
		while(l<=r){
			ll mid=(l+r)/2;
			ll cur=cek(mid, len);
			if(cur==n){
				ans+=2;
				break;
			}
			else if(cur>n){
				r=mid-1;
			}
			else l=mid+1;
		}
	}
	cout << ans << '\n';
}

/******************************************
* AUTHOR : RTG *
******************************************/
#include <bits/stdc++.h>
using namespace std;

// long long dp[(long long)1e12+1];

int main() {

	ios_base::sync_with_stdio(false);
	cin.tie(NULL);

	#ifndef ONLINE_JUDGE
    // For getting input from input.txt file
    FILE *input = freopen("/home/tharun/Documents/cpg/input.txt", "r", stdin);
    // Printing the Output to output.txt file
    FILE *output = freopen("/home/tharun/Documents/cpg/output.txt", "w", stdout);
    int start_time = (int)clock();
    #endif

    long long n;
    cin>>n;
    n*=2;
    long long ans=0;
    for(long long i=1;i*i<=n;i++){
    	if(n%i==0){
    		long long d1=i;
    		long long d2=n/i;

    		if((d2-d1+1)%2==0){
    			ans++;
    		}
    	}
    }
    cout<<2*ans;

    #ifndef ONLINE_JUDGE
    // Time taken for execution
    cout<<"\nTime = "<<clock() - start_time<<"ms";
    #endif

	return 0;
}


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

signed main(){
    ios_base::sync_with_stdio(false);cin.tie(NULL);
    int a,b;
    cin >> a >> b;
    vector <int> A(a),B(b);
    for(int i=0;i<a;i++)A[i]=i+1;
    for(int i=0;i<b;i++)B[i]=-(i+1);
    if(a>b){
        B[b-1]=-((a*(a+1)/2)-((b*(b-1)/2)));
    }
    if(b>a){
        A[a-1]=(b*(b+1)/2)-(a*(a-1)/2);
    }
    for(int i=0;i<a;i++)cout << A[i] << " ";
    for(int i=0;i<b;i++)cout << B[i] << " ";
}

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

typedef long long LL;
typedef pair<int, int> II;

const int MAXN = 1000 + 10;
int n, m, a[MAXN], b[MAXN];

int main() {
    scanf("%d%d", &n, &m);

    int rev = 0;
    if (n < m) {
        rev = 1;
        swap(n, m);
    }

    for (int i = 1; i <= n; ++i) {
        a[i] = i;
    }
    for (int i = 1; i <= m; ++i) {
        b[i] = i;
    }

    int sum = 0;
    for (int i = 1; i <= n; ++i) {
        sum += a[i];
    }
    for (int i = 1; i <= m; ++i) {
        sum -= b[i];
    }

    for (int i = 1; i <= m; ++i) {
        b[i] += sum / m;
    }
    b[m] += sum % m;

    if (rev == 0) {
        for (int i = 1; i <= m; ++i) {
            b[i] = -b[i];
        }
    } else {
        for (int i = 1; i <= n; ++i) {
            a[i] = -a[i];
        }
    }

    for (int i = 1; i <= n; ++i) {
        printf("%d ", a[i]);
    }
    for (int i = 1; i <= m; ++i) {
        printf("%d ", b[i]);
    }
    puts("");
    return 0;
}


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

inline int read(){
    int s=0,w=1;
    char ch=getchar();
    while(ch<'0'||ch>'9'){
        if(ch=='-')w=-1;ch=getchar();
    }
    while(ch>='0'&&ch<='9') s=s*10+ch-'0',ch=getchar();
    return s*w;
}

inline bool read(int& a){
int s=0,w=1;
    char ch=getchar();
    if(ch==EOF){
        return false;
    }
    while(ch<'0'||ch>'9'){
        if(ch=='-')w=-1;ch=getchar();
    }
    while(ch>='0'&&ch<='9') s=s*10+ch-'0',ch=getchar();
    a=s*w;
    return true;
}

inline void write(int x){
    if(x<0) putchar('-'),x=-x;
    if(x>9) write(x/10);
    putchar(x%10+'0');
}

inline void writeln(int x){
    if(x<0) putchar('-'),x=-x;
    if(x>9) write(x/10);
    putchar(x%10+'0');
    puts("");
}

const int MOD=998244353;

int n,k;
int f[3010][3010];

signed main(){
    read(n),read(k);
    f[1][1]=1;

    for(int i=2;i<=n;i++){
        for(int j=i;j>=1;j--){
            f[i][j]=(f[i-1][j-1]+f[i][j*2])%MOD;
        }
    }

    writeln(f[n][k]%MOD);

    return 0;
}

/*input
2525 425

*/
//#include "wall.h"
#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;

#pragma GCC optimize("unroll-loops,no-stack-protector")
//order_of_key #of elements less than x
// find_by_order kth element
#define ll long long
#define ld long double
#define pii pair<int,int>
#define piii pair<int,pii>
typedef tree<int, null_type, less<int>, rb_tree_tag, tree_order_statistics_node_update> indexed_set;
#define f first
#define s second
#define pb push_back
#define REP(i,n) for(ll i=0;i<n;i++)
#define REP1(i,n) for(int i=1;i<=n;i++)
#define FILL(n,x) memset(n,x,sizeof(n))
#define ALL(_a) _a.begin(),_a.end()
#define sz(x) (int)x.size()
#define SORT_UNIQUE(c) (sort(c.begin(),c.end()), c.resize(distance(c.begin(),unique(c.begin(),c.end()))))
#define MP make_pair
const ll INF64=4e18;
const int INF=0x3f3f3f3f;
const ll MOD=998244353;
const ld PI=acos(-1);
const ld eps=1e-9;
#define lowb(x) x&(-x)
#define MNTO(x,y) x=min(x,(__typeof__(x))y)
#define MXTO(x,y) x=max(x,(__typeof__(x))y)
ll mult(ll a,ll b){
    return ((a%MOD)*(b%MOD))%MOD;
}
ll mypow(ll a,ll b){
    if(b<=0) return 1;
    ll res=1LL;
    while(b){
        if(b&1){
            res=(res*a)%MOD;
        }
        a=(a*a)%MOD;
        b>>=1;
    }
    return res;
}
const ll maxn=3e3+5;
const ll maxlg=__lg(maxn)+2;
ll dp[maxn][maxn];
ll pref[maxn];
ll rec(int n,int k){
    if(n==0 and k==0) return 1;
    if(k==0) return 0;
    if(n<k) return 0;
    if(dp[n][k]) return dp[n][k];
    return dp[n][k]=(rec(n-1,k-1)+rec(n,2*k))%MOD;
}
int main(){
    ios::sync_with_stdio(false),cin.tie(0);
    int n,k;
    cin>>n>>k;
    cout<<rec(n,k)<<'\n';
}


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

#define int long long

int32_t main()
{
#ifndef ONLINE_JUDGE
	freopen("input.txt", "r", stdin);
	freopen("output.txt", "w", stdout);
#endif

	int l;
	cin >> l;
	vector<array<int, 12>> dp(l + 1);
	for(int i = 1; i <= l; i++) {
		dp[i][0] = 1;
	}
	for(int cut = 1; cut <= 11; cut++) {
		dp[1][cut] = 0;
	}

	for(int i = 2; i <= l; i++) {
		for(int cut = 1; cut <= 11; cut++) {
			dp[i][cut] = dp[i - 1][cut] + dp[i - 1][cut - 1];
		}
	}
	// for(int i = 1; i <= l; i++) {
	// 	for(int cut = 0; cut <= 11; cut++) {
	// 		cout << dp[i][cut] << ' ';
	// 	}
	// 	cout << endl;
	// }

	cout << dp[l][11];

	return 0;
}

#include<iostream>
#define FAST ios::sync_with_stdio(false),cin.tie(0),cout.tie(0)

using namespace std;
typedef long long ll;

const int MAXN=1e5+5;

ll cal(ll n) {
    ll ans=1; int cnt=11;
    for(int i=1;i<12;++i) {
        ans*=n-i;
        ans/=i;
    }
    return ans;
}
int main() {
    FAST;
    ll n; cin>>n;
    cout<<cal(n)<<endl;
}


#include<iostream>
#include<iomanip>
#include<string>
#include<vector>
#include<algorithm>
#include<utility>
#include<tuple>
#include<map>
#include<queue>
#include<deque>
#include<set>
#include<stack>
#include<numeric>
#include<cstdio>
#include<cstdlib>
#include<cstring>
#include<cmath>

using namespace std;

struct Edge {
  int to;
  long long weight;
  Edge() : to(0), weight(0) {}
  Edge(int to, long long weight) : to(to), weight(weight) {}
  Edge(const Edge& e) {
    to = e.to;
    weight = e.weight;
  }
  bool operator>(const Edge &e) const { return weight > e.weight; }
  bool operator<(const Edge &e) const { return weight < e.weight; }
  bool operator==(const Edge &e) const { return weight == e.weight; }
  bool operator<=(const Edge &e) const { return weight <= e.weight; }
  bool operator>=(const Edge &e) const { return weight >= e.weight; }
};

using ll = long long;
using ld = long double;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
using Graph = vector<vector<int>>;
using weightedGraph = vector<vector<Edge>>;
using heap = priority_queue<int, vector<int>, greater<int>>;

const ll BIL = 1e9;
const ll MOD = 1e9 + 7;
const ll INF = 1LL << 60;
const int inf = 1 << 29;
const ld PI = 3.141592653589793238462643383;

struct SegmentTree {
  int sz;
  vector<int> t;
  SegmentTree(int n) {
    sz = 1;
    while(sz < n) sz *= 2;
    t.assign(2 * sz - 1, 0);
  }
  void init(int idx, ll val) {
    idx += sz-1;
    t[idx] = val;
    return;
  }
  void update(int idx, int val) {
    idx += sz - 1;
    t[idx] = val;
    while(idx > 0) {
      idx = (idx - 1) / 2;
      if(t[idx] > val) break;
      t[idx] = val;
    }
    return;
  }
  void update(int l, int r, ll val, int now=0, int a=0, int b=-1) {
    if(now >= t.size()) return;
    if(b < 0) b = sz;
    if(l < 0) l = 0;
    if(r > sz) r = sz;
    if(r < a || l > b) return;
    if(l <= a && b <= r) {
      t[now] -= val;
      return;
    }
    update(l, r, val, now*2+1, a, (a+b)/2);
    update(l, r, val, now*2+2, (a+b)/2, b);
    return;
  }
  int getMax(int l, int r, int now=0, int a=0, int b=-1) {
    if(now >= t.size()) return 0;
    if(b < 0) b = sz;
    if(l < 0) l = 0;
    if(r > sz) r = sz;
    if(l > b || r < a) return 0;
    if(l <= a && r >= b) return t[now];
    int res = 0;
    res = max(res, getMax(l, r, 2*now+1, a, (a+b)/2));
    res = max(res, getMax(l, r, 2*now+2, (a+b)/2, b));
    return res;
  }
  ll getElement(int idx) {
    if(idx == 0) return t[0];
    ll res = t[idx];
    return res += getElement((idx-1)/2);
  }
  ll operator[](int idx) {
    idx += sz-1;
    return getElement(idx);
  }
};

int main(int argc,char* argv[]){
  cin.tie(0);
  ios::sync_with_stdio(0);
  cout << fixed << setprecision(20);
  int n;
  cin >> n;
  vector<ll> a(n);
  map<int, ll> mp;
  for(int i=0;i<n;i++) {
    ll k;
    cin >> k;
    k %= 200;
    a[i] = k;
    mp[k]++;
  }
  ll ans = 0;
  for(auto e : mp) {
    if(e.second == 1) continue;
    ll t = e.second;
    ans += t * (t-1) / 2;
  }
  cout << ans << endl;
  return 0;
}

#include <iostream>
#include <vector>
#include <cmath>
#include <algorithm>
#include <cstring>
#include <unordered_map>
using namespace std;
typedef long long ll;

int main() {

	ios_base::sync_with_stdio(0);
	cin.tie(0);
	cout.tie(0);

	int n;
	cin >> n;
	vector<int> arr(n);
	vector<int> rem(201, 0);

	ll ans = 0;
	for (int i = 0; i < n; i++) {
		cin >> arr[i];
		arr[i] %= 200;
		ans += rem[arr[i]];
		rem[arr[i]]++;
	}

	cout << ans << endl;

	return 0;
}


#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <bits/stdc++.h>

using namespace __gnu_pbds;
using namespace std;

using ll = long long;
using ld = long double;

typedef tree<
        int,
        null_type,
        less<int>,
        rb_tree_tag,
        tree_order_statistics_node_update>
        ordered_set;

#define mp make_pair

const int MOD =  998244353;

int mul(int a, int b) {
    return (1LL * a * b) % MOD;
}

int add(int a, int b) {
    int s = (a+b);
    if (s>=MOD) s-=MOD;
    return s;
}

int sub(int a, int b) {
    int s = (a+MOD-b);
    if (s>=MOD) s-=MOD;
    return s;
}

int po(int a, ll deg)
{
    if (deg==0) return 1;
    if (deg%2==1) return mul(a, po(a, deg-1));
    int t = po(a, deg/2);
    return mul(t, t);
}

int inv(int n)
{
    return po(n, MOD-2);
}

mt19937 rnd(time(0));

const int LIM = 3e5 + 5;

vector<int> facs(LIM), invfacs(LIM);

void init()
{
    facs[0] = 1;
    for (int i = 1; i<LIM; i++) facs[i] = mul(facs[i-1], i);
    invfacs[LIM-1] = inv(facs[LIM-1]);
    for (int i = LIM-2; i>=0; i--) invfacs[i] = mul(invfacs[i+1], i+1);
}

int C(int n, int k)
{
    if (n<k) return 0;
    if (n<0 || k<0) return 0;
    return mul(facs[n], mul(invfacs[k], invfacs[n-k]));
}

/*struct DSU
{
    vector<int> sz;
    vector<int> parent;
    void make_set(int v) {
        parent[v] = v;
        sz[v] = 1;
    }

    int find_set(int v) {
        if (v == parent[v])
            return v;
        return find_set(parent[v]);
    }

    void union_sets(int a, int b) {
        find_set(a);
        find_set(b);

        a = find_set(a);
        b = find_set(b);

        if (a != b) {
            if (sz[a] < sz[b])
                swap(a, b);
            parent[b] = a;
            sz[a] += sz[b];
        };
    }

    DSU (int n)
    {
        parent.resize(n);
        sz.resize(n);
        for (int i = 0; i<n; i++) make_set(i);
    }
};*/

/*

 dp[cnt][sum][xor]

 Bit dp

 */

int main()
{
    ios_base::sync_with_stdio(0);
    cin.tie(nullptr);

    init();

    int n, m; cin>>n>>m;

    vector<int> dp(m+1);

    dp[0] = 1;
    for (int sum = 2; sum<=m; sum+=2)
    {
        for (int odd = 0; odd<=min(n, sum); odd+=2)
        {
            dp[sum] = add(dp[sum], mul(C(n, odd), dp[(sum-odd)/2]));
        }
    }
    cout<<dp[m];

}

#include<bits/stdc++.h>
#define x first
#define y second
#define pb push_back
#define eb emplace_back
#define all(a) (a).begin(),(a).end()
#define SZ(a) (int)(a).size()
#define FOR(i, a, b) for(int i=(a); i<=(b); ++i)
#define ROF(i, a, b) for(int i=(a); i>=(b); --i)
#define make_unique(a) sort(all((a))), (a).resize(unique(all((a)))-(a).begin())
#define pc(x) putchar(x)
#define make_pair MP
#define make_tuple MT

using namespace std;

typedef long long i64;
typedef tuple<int,int,int> iii;
typedef pair<int,int> pii;
typedef pair<i64, i64> pll;
typedef vector<int> vi;
typedef vector<vi> vvi;

void solve(){
    int n;
    scanf("%d",&n);
    vi nxt(n+1);
    FOR(i, 1, n) scanf("%d",&nxt[i]);
    vi visit(n+1), onstack(n+1);
    stack<int> stk;
    int cnt = 0;
    FOR(i, 1, n){
        if(visit[i]) continue;
        int nw = i;
        while(1){
            visit[nw] = 1;
            onstack[nw] = 1;
            stk.push(nw);
            if(visit[nxt[nw]]){
                if(onstack[nxt[nw]]) ++cnt;
                while(!stk.empty()){
                    onstack[stk.top()] = 0;
                    stk.pop();
                }
                break;
            }else{
                nw = nxt[nw];
            }
        }
    }
    int ans = 1;
    int mod = 998244353;
    FOR(i, 1, cnt) ans = (ans+ans >= mod) ? ans+ans-mod : ans+ans;
    printf("%d",(ans-1+mod)%mod);
}

int main(){
    solve();
	return 0;
}
/*
 *
 *
 *
 *
 *
 *
 *
 *
 *
 *
 */


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

#define FOR(i,a,b) for(int i=(a);i<(b);++i)
#define REP(i,n)   FOR(i,0,n)
#define ALL(a)     (a).begin(),(a).end()
#define RALL(a)     (a).rbegin(),(a).rend()
#define PRINT(a)   cout << (a) << endl

#define pb push_back
#define eb emplace_back
#define mp make_pair
#define Fi first
#define Se second

#define debug(x) cerr << x << " " << "(L:" << __LINE__ << ")" << '\n';

using ll = long long int;
using P = pair<int,int>;
using vi = vector<int>;
using vvi = vector<vi>;
using vvvi = vector<vvi>;
using pii = pair<int, int>;

template <typename T> using PQ = priority_queue<T>;
template <typename T> using minPQ = priority_queue<T, vector<T>, greater<T>>;

template<class T>bool chmax(T &a, const T &b) { if (a<b) { a=b; return 1; } return 0; }
template<class T>bool chmin(T &a, const T &b) { if (b<a) { a=b; return 1; } return 0; }

const int INF = 1001001001;
const ll LINF = 1001001001001001001ll;
const int MOD = 1e9 + 7;

int main(){
  int x;
  cin >> x;
  cout << (x >= 0 ? x : 0 ) << endl;
}

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

#define all(x) (x).begin(),(x).end()
#define print(x) cout << (x) << endl
typedef long long ll;
using P = pair<int,int>;
using Graph = vector<vector<int>>;
//const ll MOD = 1000000007;
const ll MOD = 998244353;

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

void solve() {
    int n;  cin >> n;
    vector<int> t(n + 1, -1);
    queue<int> pr;
    for(int i=2; i<=n; i++){
        if(t[i] < 0){
            pr.push(i);
            for(int j=i+i; j<=n; j+=i) t[j] = 0;
        }
    }
    vector<int> a(n + 1, -1);
    a[1] = 1;
    for(int i=2; i<=n; i++){
        if(t[i] == -1){
            a[i] = 2;
            for(int j=i+i; j<=n; j+=i) a[j] = a[i] + 1;
        }else{
            for(int j=i+i; j<=n; j+=i) a[j] = a[i] + 1;
        }
    }
    for(int i=1; i<n+1; i++) cout << a[i] << " ";
    int ma = 0;
    cout << endl;
    return;
}

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

    int t;
    //cin >> t;
    t = 1;
    while(t--) solve();
    return 0;
}


#include <bits/stdc++.h>
#define mp make_pair
#define fi first
#define se second
#define pb push_back
#define eb emplace_back
#define all(x) (x).begin(), (x).end()
#define rall(x) (x).rbegin(), (x).rend()
#define forn(i, n) for (int i = 0; i < (int)(n); ++i)
#define for1(i, n) for (int i = 1; i <= (int)(n); ++i)
#define ford(i, a, b) for (int i = (int)(a); i >= (int)b; --i)
#define fore(i, a, b) for (int i = (int)(a); i <= (int)(b); ++i)
#define rep(i, l, r) for (int i = (l); i <= (r); i++)
#define per(i, r, l) for (int i = (r); i >= (l); i--)
#define ms(x, y) memset(x, y, sizeof(x))
#define SZ(x) int(x.size())
#define fk cerr<<"fk"<<endl
#define db(x) cerr<<(#x)<<'='<<(x)<<endl
using namespace std;
typedef pair<int, int> pii;
typedef vector<int> vi;
typedef vector<pii> vpi;
typedef vector<vi> vvi;
typedef long long i64;
typedef vector<i64> vi64;
typedef vector<vi64> vvi64;
typedef pair<i64, i64> pi64;
typedef double ld;
template<class T> bool uin(T &a, T b) { return a > b ? (a = b, true) : false; }
template<class T> bool uax(T &a, T b) { return a < b ? (a = b, true) : false; }
//1.integer overflow (1e5 * 1e5) (2e9 + 2e9)
//2.runtime error
//3.boundary condition
const int N=2100;
int h,w,vis[N][N],dir[4][2]={{-1,0},{1,0},{0,1},{0,-1}};
char mat[N][N];
vector< pair<int,int> > idx[30];
bool ok(int x,int y){
    if(x<1 || x>h || y<1 || y>w) return false;
    if(mat[x][y]=='#') return false;
    if(vis[x][y]==1) return false;
    return true;
}
int bfs(int sx,int sy){
    queue< pair< pair<int,int>,int > > q;
    q.push(mp(mp(sx,sy),0));
    vis[sx][sy]=1;
    while(!q.empty()){
        pair< pair<int,int>,int > now=q.front();
        q.pop();
        int nx=now.fi.fi,ny=now.fi.se;
        if(mat[nx][ny]=='G') return now.se;
        char temp=mat[nx][ny];
        if(temp>='a' && temp<='z'){
            for(pair<int,int> np:idx[int(temp-'a')]){
                vis[np.fi][np.se]=1;
                q.push(mp(mp(np.fi,np.se),now.se+1));
            }
            idx[int(temp-'a')].clear();
        }
        for(int i=0; i<4; ++i){
            int tx=nx+dir[i][0];
            int ty=ny+dir[i][1];
            if(ok(tx,ty)){
                //if(mat[tx][ty]=='G') return now.se+1;
                vis[tx][ty]=1;
                q.push(mp(mp(tx,ty),now.se+1));
            }
        }
    }
    return -1;
}
int main() {
    ios::sync_with_stdio(false);
    cin.tie(0);
    cout.precision(10);
    cout << fixed;
#ifdef LOCAL_DEFINE
    freopen("input.txt", "r", stdin);
#endif
    cin>>h>>w;
    int sx,sy;
    for1(i, h){
        for1(j, w){
            cin>>mat[i][j];
            if(mat[i][j]>='a' && mat[i][j]<='z'){
                int num=int(mat[i][j]-'a');
                idx[num].eb(mp(i,j));
            }
            if(mat[i][j]=='S'){
                sx=i;
                sy=j;
            }
        }
    }
    ms(vis,0);
    cout<<bfs(sx,sy)<<'\n';
#ifdef LOCAL_DEFINE
    cerr << "Time elapsed: " << 1.0 * clock() / CLOCKS_PER_SEC << " s.\n";
#endif
    return 0;
}

#include <bits/stdc++.h>
#define MOD (long long)(1E9+7)
#define rep(i, n) for(int i = 0; i < n; i++)

using namespace std;
int table[2000][2000];
void bfs(queue<pair<int,int>> &que, vector<vector<pair<int,int>>> &warp, int &now, int &w, int &h) {
  int n = que.size();
  rep(lll,n) {
	auto x = que.front();
    int i = x.first;
 	int j = x.second;
    que.pop();
    if(table[i][j] >=10000000) {
    	int abc = table[i][j] -10000000-1;
      	table[i][j] = now+1;
      	rep(k, warp[abc].size()) {
        	auto yy = warp[abc][k];
          	if(table[yy.first][yy.second] > now+1) {
              	que.push(make_pair(yy.first,yy.second));
              	table[yy.first][yy.second] = -1;
            }
        }
    }
    if(table[i][j] > now || table[i][j] == -1) {
      table[i][j] = now;
      if(i>0 && (table[i-1][j] == -1 || table[i-1][j]>now+1)) {
      	que.push(make_pair(i-1,j));
      }
      if(i<h-1 && (table[i+1][j]  == -1 || table[i+1][j]>now+1)) {
      	que.push(make_pair(i+1,j));
      }
      if(j>0 && (table[i][j-1] == -1 || table[i][j-1]>now+1)) {
      	que.push(make_pair(i,j-1));
      }
      if(j<w-1 && (table[i][j+1] == -1 || table[i][j+1]>now+1) ) {
      	que.push(make_pair(i,j+1));
      }

    }
  }
  if(!que.empty()) {
    now++;
  	bfs(que, warp, now,w,h);
  }
}
int main(){
  	int h,w,sx,sy,gx,gy;
  	string s;
	cin >> h >> w;
  	vector<vector<pair<int,int>>> warp(26);
  	rep(i,h)rep(j,w) table[i][j] = -1;
  	rep(i,h) {
    	cin >> s;
      	rep(j,w) {
        	if(s[j] >= 'a' && s[j] <= 'z') {
            	table[i][j] = 10000000+s[j]-'a'+1;
              	warp[(s[j]-'a')].push_back(make_pair(i, j));
            } else if(s[j] == 'S') {
              	sx = j; sy = i;
            } else if(s[j] == 'G') {
               gx =  j; gy = i;
            } else if(s[j] == '.') {
              continue;
            } else if(s[j] == '#') {
             	table[i][j] = -2;
            }
        }
    }

 	queue<pair<int,int>> que;
  	que.push(make_pair(sy,sx));
  	int now=0;
  	bfs(que, warp, now,w,h);
	cout << table[gy][gx] << endl;
}


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

int main(){
  int a, b, c;
  cin >> a >> b >> c;
  if(a + b == 2 * c || a + c == 2 * b || b + c == 2 * a)
    cout << "Yes" << endl;
  else
    cout << "No" << endl;
  return 0;
}

#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 ff              first
#define ss              second
#define int 			long long
#define pb              push_back
#define mp              make_pair
#define mt              make_tuple
#define pii             pair<int,int>
#define vi              vector<int>
#define mii             map<int,int>
#define pqb             priority_queue<int>
#define max_size        100000000
#define pqs             priority_queue<int,vi,greater<int> >
#define setbits(x)      __builtin_popcountll(x)
#define mod             1000000007
#define w(t)			int t; cin >> t; while(t--)
#define inf             1e3
#define ps(x,y)         fixed<<setprecision(y)<<x
#define mk(arr,n,type)  type *arr=new type[n];
#define range(a,b)      substr(a,b-a+1)
#define mina(a,b,c)		min(a, min(b, c))
#define maxa(a,b,c)		max(a, max(b, c))
#define endl 			'\n'
#define trace(x)        cerr<<#x<<": "<<x<<" "<<endl;
#define FIO             ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0)
#define FOR(x,y)		for(int i = x; i < y; i++)
#define oset 			tree<int, null_type,less<int>, rb_tree_tag,tree_order_statistics_node_update>

bool sortbysec(const pair<int,int> &a, const pair<int,int> &b){ return (a.second < b.second); }

bool specsort(const pair<int,int> &a, const pair<int,int> &b){
	if(a.first == b.first) return (a.second < b.second);
	else return (a.first < b.first);
}
int64_t ceil_div(int64_t a, int64_t b) {if(a%b != 0){ return ((a/b)+1);} else{ return (a/b);}}

double max(double a, double b){ if(a >= b){ return a; } else{ return b; } }

double min(double a, double b){if(a <= b){return a;} else{return b;}}

bool modd(double a, double b){if(floor(a/b) == ceil(a/b)){return true;} return false;}

bool stringsort(const string &a, const string &b){return a.length() > b.length();}

int32_t main(){
	FIO;
	int a,b,c;
	cin >> a >> b >> c;
	if(a*a + b*b < c*c) cout << "Yes" << endl;
	else cout << "No" << endl;
    return 0;
}


// Contest: AtCoder Regular Contest 104 (https://atcoder.jp/contests/arc104)
// Problem: A: Plus Minus (https://atcoder.jp/contests/arc104/tasks/arc104_a)

// region boilerplate
#include <algorithm>
#include <array>
#include <bitset>
#include <cassert>
#include <cmath>
#include <chrono>
#include <cstdint>
#include <deque>
#include <exception>
#include <forward_list>
#include <functional>
#include <initializer_list>
#include <iomanip>
#include <iostream>
#include <iterator>
#include <limits>
#include <list>
#include <map>
#include <memory>
#include <numeric>
#include <queue>
#include <random>
#include <set>
#include <stack>
#include <string>
#include <tuple>
#include <type_traits>
#include <unordered_map>
#include <unordered_set>
#include <utility>
#include <vector>

#if __cplusplus >= 201703L
#   include <optional>
#   include <string_view>
#   include <variant>
#endif

using namespace std;

#if __cplusplus >= 201703L
#   define all(a)      begin(a),end(a)
#   define sz(x)       ((int)size(x))
#else
#   define all(a)      (a).begin(),(a).end()
#   define sz(x)       ((int)(x).size())
#endif

#define rep(a, b)      for(int a = 0; a < (b); ++a)
#define reps(a, b, c)  for(int a = (b); a < (c); ++a)
#define trav(a, b)     for(auto& a : b)

using ll = long long;
using ld = long double;
using u64 = uint64_t;
using u32 = uint32_t;

using pi = pair<int, int>;
using pl = pair<ll, ll>;
using vi = vector<int>;
using vl = vector<ll>;
using vvi = vector<vi>;
using vpi = vector<pi>;

#if __cplusplus >= 201703L
#   define MAYBE_UNUSED [[maybe_unused]]
#else
#   define MAYBE_UNUSED
#endif

MAYBE_UNUSED static constexpr int INF = (int)1e9 + 5;
MAYBE_UNUSED static constexpr ll INFL = (ll)1e18 + 5;
MAYBE_UNUSED static mt19937 rng((u32)chrono::duration_cast<chrono::nanoseconds>(chrono::high_resolution_clock::now().time_since_epoch()).count());
//endregion

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

    int a, b; cin >> a >> b;
    int y = (a - b) / 2;
    cout << (a - y) << ' ' << y << '\n';

    return 0;
}

#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for(int i = 0; i < (n); ++i)
using ll = long long;
using P = tuple<ll, ll, int>;

int main() {
    int n; cin >> n;
    vector<P> ps;
    rep(i, n) {
        ll x, y;
        cin >> x >> y;
        ps.emplace_back(x, y, i);
    }

    vector<bool> pushed(n);
    vector<P> use;
    auto push = [&]() -> void {
        rep(i, 3) {
            auto[x, y, id] = ps[i];
            if(pushed[id]) continue;
            use.push_back(ps[i]);
            pushed[id] = true;
        }
        rep(_i, 3) {
            int i = n - 1 - _i;
            auto[x, y, id] = ps[i];
            if(pushed[id]) continue;
            use.push_back(ps[i]);
            pushed[id] = true;
        }
    };

    sort(ps.begin(), ps.end());
    push();
    sort(ps.begin(), ps.end(), [&](auto a, auto b) {
        auto[x, y, i] = a;
        auto[xb, yb, ib] = b;
        return y < yb;
    });
    push();

    vector<int> dist;
    for(auto &[x, y, i] : use) {
        for(auto &[x2, y2, i2] : use) {
            if(i == i2) continue;
            ll d = max(abs(x - x2), abs(y - y2));
            dist.push_back(d);
        }
    }

    sort(dist.rbegin(), dist.rend());

    cout << dist[2] << '\n';
    return 0;
}


/*
ID: meadri01
LANG: C
TASK: test
*/
#include<bits/stdc++.h>
#include<ext/pb_ds/assoc_container.hpp>
#include<ext/pb_ds/tree_policy.hpp>
#define int 				long long
#define w(t)                int t;cin>>t;while(t--)
#define pb                  push_back
#define mk                  make_pair
#define ascSort(v)          sort(v.begin(), v.end())
#define descSort(v)         sort(v.begin(), v.end(), greater<int>())
#define ff                  first
#define ss                  second
#define pi                  pair<int,int>
#define vi                  vector<int>
#define mi                  map<int,int>
#define fill(a,x)           fill(a.begin(), a.end(), x)
#define iota(a,x)           iota(a.begin(), a.end(), x)
#define umapi               unordered_map<int,int>

const int mod1=998244353;
const int mod2=1e9+7;
const int inf=mod2;
using namespace std;
using namespace __gnu_pbds;

typedef tree<int, null_type, less<int>, rb_tree_tag, tree_order_statistics_node_update>PBDS;

void FIO(){
	#ifndef ONLINE_JUDGE
		freopen("input.txt", "r", stdin);
		freopen("output.txt", "w", stdout);
	#endif
	ios_base::sync_with_stdio(false);
    cin.tie(NULL);
}
void usaco(string filename) {
  // #pragma message("be careful, freopen may be wrong")
	freopen((filename + ".in").c_str(), "r", stdin);
	freopen((filename + ".out").c_str(), "w", stdout);
}

void testcase(){
	int n;cin>>n;
	vi a(n);
	for(int i=0; i<n; i++)cin>>a[i];
	ascSort(a);
	double x=a[(n-1)/2]/2.0,ans2=0.0,ans1=0.0;
	for(int i=0; i<n; i++){
		if(a[i]<=2.0*x){
			ans1+=x;
		}
		else{
			ans1+=x+a[i]*1.0 - 2*x;
		}
	}
	x=a[(n+1)/2]/2.0;
	for(int i=0; i<n; i++){
		if(a[i]<=2.0*x){
			ans2+=x;
		}
		else{
			ans2+=x+a[i]*1.0 - 2*x;
		}
	}
	cout<<fixed<<setprecision(10)<<min(ans1,ans2)/(n*1.0)<<"\n";
}

int32_t main(){

	FIO();
	//usaco("test");
	int t=1;
	//cin>>t;
	while(t--){
		testcase();
	}
	return 0;

}

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

/*#include <ext/pb_ds/assoc_container.hpp>
using namespace __gnu_pbds;
using namespace std;

typedef tree<long long, null_type, less<long long>, rb_tree_tag,
          tree_order_statistics_node_update>
 is;*/

#define fb find_by_order
#define ok order_of_key

#define mem(x,y) memset(x,y,sizeof x)

typedef long long ll;
typedef int ii;

typedef pair<ll,ll> pi;
typedef vector<pi> vii;

#define map unordered_map

#define INF 100000000000007
#define pi 3.141592654

#define T while(t--)
#define for2(i,a,b) for(i=a;i>=b;i--)
#define for3(i,a,b) for(i=a;i<=b;i=i+2)
#define for1(i,a,b) for(i=a;i<=b;i=i+1)
#define for4(i,a,b) for(i=a;i>=b;i=i-2)

#define pb push_back
#define pf push_front
#define mp make_pair

#define ff first
#define ss second

#define si set<ll>
#define se multiset<ll>

typedef long double ld;
typedef vector<ll> vi;

#define all(v) sort(v.begin(),v.end())
#define all1(v) sort(v.rbegin(),v.rend())

#define pff(uuv) printf("%lld\n",uuv)

#define pf1(uu) printf("%.20Lf\n",uu)

bool comp(pair<ll,char> aa, pair<ll,char> bb) {
    if (aa.ff != bb.ff) return aa.ff > bb.ff;
    return aa.ss < bb.ss;
}
bool comp1(pair<ll,char> aa, pair<ll,char> bb) {
    if (aa.ff != bb.ff) return aa.ff < bb.ff;
    return aa.ss > bb.ss;
}
bool comp2(pair<ll,ll> aa, pair<ll,ll> bb) {
    if (aa.ff != bb.ff) return aa.ff > bb.ff;
    return aa.ss < bb.ss;
}
bool comp3(pair<ll,ll> aa, pair<ll,ll> bb) {
    if (aa.ff != bb.ff) return aa.ff < bb.ff;
    return aa.ss > bb.ss;
}

ll rup(ll ik,ll ikk){

 if(ik%ikk==0) return ik/ikk;
 else return (ik/ikk)+1;

}
ll gcd(ll a,ll b){
 if(b==0) return a;

 return gcd(b,a%b);

}
ll lcm(ll a ,ll b){

 return (a*b)/gcd(a,b);

}

ld ex(ld x,ld y){

    return x+y-min(y,2*x);

}

ii main(){

    ios::sync_with_stdio(0);
    cin.tie(0);
    cout.tie(0);
    ll t=1;
    //cin>>t;
    while(t--){

        ll n;
        ll i;
        ld x;
        cin>>n;
        vector<ld> v;
        vi v2;
        for1(i,1,n){

            cin>>x;
            v.pb(x/2);
          v2.pb(x);

        }
        all(v);

        if(n%2==1){

            ll pp=rup(n,2);

            ld sum=0;

            for1(i,0,n-1){

                sum+=ex(v[pp-1],v2[i]);
                //cout<<sum<<"\n";

            }

            //cout<<sum<<"\n";

            sum/=n;

            pf1(sum);

        }
        else{

            ll pp=n/2;
            ll qq=rup(n,2);

            ld sum=0;
            ld sum1=0;

            for1(i,0,n-1){

                sum+=ex(v[pp-1],v2[i]);

            }

            sum/=n;

            for1(i,0,n-1){

                sum1+=ex(v[qq-1],v2[i]);

            }

            sum1/=n;

            ld ans=min(sum,sum1);

            pf1(ans);

        }

     }

}


#include <bits/stdc++.h>
using namespace std;
void __print(int x) {cout << x;}
void __print(long x) {cout << x;}
void __print(long long x) {cout << x;}
void __print(unsigned x) {cout << x;}
void __print(unsigned long x) {cout << x;}
void __print(unsigned long long x) {cout << x;}
void __print(float x) {cout << x;}
void __print(double x) {cout << x;}
void __print(long double x) {cout << x;}
void __print(char x) {cout << '\'' << x << '\'';}
void __print(const char *x) {cout << '\"' << x << '\"';}
void __print(const string &x) {cout << '\"' << x << '\"';}
void __print(bool x) {cout << (x ? "true" : "false");}
template<typename T, typename V>
void __print(const pair<T, V> &x) {cout << '{'; __print(x.first); cout << ','; __print(x.second); cout << '}';}
template<typename T>
void __print(const T &x) {int f = 0; cout << '{'; for (auto &i: x) cout << (f++ ? "," : ""), __print(i); cout << "}";}
void _print() {cout << "\n";}
template <typename T, typename... V>
void _print(T t, V... v) {__print(t); if (sizeof...(v)) cout << ", "; _print(v...);}
#define debug(x...) cout << #x << " = "; _print(x)
typedef long long ll; typedef vector<int> vi; typedef vector<ll> vll;
#define rep(i,a,b) for (ll i = (a); i < (b); ++i)
#define per(i,a,b) for (int i = (b)-1; i >= (a); --i)
#define all(x) begin(x), end(x)
#define mp make_pair
#define pb push_back
#define ff first
#define ss second
#define fast ios_base::sync_with_stdio(NULL);cin.tie(NULL);cout.tie(NULL)
const int mod = 1e9 + 7, mxn = 1e5 + 1;

int solve(){
    char s, t;
    cin>> s>> t;
    if(s == 'Y')
        t = (t - 'a') + 'A';
    cout<< t<< "\n";
    return 0;
}
//Counting problems: Sometimes easier to find complement of the answer

int main()
{
    fast;
    int t = 1;
    // cin>> t;
    while(t--){
        solve();
    }
    return 0;
}
//v.clear(), vis.clear(); vis.resize(n + 1, 0), v.resize(n + 1);

/*  inv[1] = 1; // inv is ll
    for(int i=2; i<=mxn; ++i)
        inv[i]=mod-mod/i*inv[mod%i]%mod;*/

// lower bound   >=
// upper bound   >
// vector<int>().swap(vec); //free memory from vec

#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
int main()
{
   char n,s;
   cin>>n>>s;
   if(n=='N'){
    s=(s>='A'&&s<='Z')?s+32:s;
   }
   else{
    s=(s>='a'&&s<='z')?s-32:s;
   }
   cout<<s;
}


#include <bits/stdc++.h>
#define rep(i,n) for(int i = 0; i < (int)(n); i++)
#define rrep(ri,n) for(int ri = (int)(n-1); ri >= 0; ri--)
#define rep2(i,x,n) for(int i = (int)(x); i < (int)(n); i++)
#define rrep2(ri,x,n) for(int ri = (int)(n-1); ri >= (int)(x); ri--)
#define repit(itr,x) for(auto itr = x.begin(); itr != x.end(); itr++)
#define rrepit(ritr,x) for(auto ritr = x.rbegin(); ritr != x.rend(); ritr++)
#define ALL(x) x.begin(), x.end()
using ll = long long;
using namespace std;

int main(){
  int n, t;
  cin >> n >> t;
  vector<int> a(n);
  rep(i, n) cin >> a.at(i);
  vector<int> b, c;
  rep(i, n){
    if(i < n/2){
      b.push_back(a.at(i));
    }else{
      c.push_back(a.at(i));
    }
  }
  vector<ll> d;
  rep(bit, 1 << b.size()){
    ll add = 0;
    rep(i, b.size()){
      if((bit & (1 << i)) != 0){
        add += b.at(i);
      }
    }
    d.push_back(add);
  }
  sort(ALL(d));
  d.push_back(LLONG_MAX);
  ll ans = 0;
  rep(bit, 1 << c.size()){
    ll add = 0;
    rep(i, c.size()){
      if((bit & (1 << i)) != 0){
        add += c.at(i);
      }
    }
    if(add > t) continue;
    auto itr = upper_bound(ALL(d), t - add);
    itr--;
    add += *itr;
    ans = max(ans, add);
  }
  cout << ans << endl;
  return 0;
}

#include <bits/stdc++.h>

using namespace std;

#define eb emplace_back
#define ii pair<int, int>
#define OK (cerr << "OK" << endl)
#define debug(x) cerr << #x " = " << (x) << endl
#define ff first
#define ss second
#define int long long
#define tt tuple<int, int, int>
#define all(x) x.begin(), x.end()
#define vi vector<int>
#define vii vector<pair<int, int>>
#define vvi vector<vector<int>>
#define vvii vector<vector<pair<int, int>>>
#define Mat(n, m, v) vector<vector<int>>(n, vector<int>(m, v))
#define endl '\n'

constexpr int INF = (sizeof(int) == 4 ? 1e9 : 2e18) + 1e5;
constexpr int MOD = 1e9 + 7;
constexpr int MAXN = 2e5 + 3;

set<int, greater<int>> s;
int n;
vi arr;
int ans = INF;
int m;
void f1(int idx, int cur) {
  if (idx == n / 2) {
    s.emplace(cur);
    return;
  }
  f1(idx + 1, cur);
  f1(idx + 1, cur + arr[idx]);
}

void f2(int idx, int cur) {
  if (idx == n) {
    auto it = s.lower_bound(m - cur);
    if (it != s.end())
      ans = min(ans, m - (cur + *it));
    return;
  }
  f2(idx + 1, cur);
  f2(idx + 1, cur + arr[idx]);
}

// #define MULTIPLE_TEST_CASES
void solve() {
  cin >> n >> m;
  arr.resize(n);
  for (int &x : arr)
    cin >> x;
  f1(0, 0);
  f2(n / 2, 0);
  cout << m - ans << endl;
}

signed main() {
  // const string FILE_NAME = "";
  // freopen((FILE_NAME + string(".in")).c_str(), "r", stdin);
  // freopen((FILE_NAME + string(".out")).c_str(), "w", stdout);
  ios_base::sync_with_stdio(false);
  cin.tie(nullptr), cout.tie(nullptr);

  int t = 1;
#ifdef MULTIPLE_TEST_CASES
  cin >> t;
#endif
  while (t--)
    solve();
}


#include <iostream>
#include <algorithm>
using namespace std;

int n, k, p[59][59], tp[59][59], ds[59], sz[59];

int uf(int n)
{
	if (ds[n] == n) return n;
	return ds[n] = uf(ds[n]);
}

bool chk(int a, int b)
{
	for (int i = 1; i <= n; i++)
		if (p[i][a] + p[i][b] > k)
			return false;
	return true;
}

int main()
{
	ios::sync_with_stdio(false);
	cin.tie(0); cout.tie(0);
	cin >> n >> k;
	for (int i = 1; i <= n; i++)
		for (int j = 1; j <= n; j++) {
			cin >> p[i][j];
			tp[i][j] = p[i][j];
		}
	long long ans = 1, md = 998244353;
	for (int ti = 0; ti < 2; ti++) {
		for (int i = 1; i <= n; i++) {
			ds[i] = i; sz[i] = 1;
		}
		for (int i = 1; i <= n; i++) {
			for (int j = 1; j < i; j++) {
				if (chk(i, j)) {
					int ua = uf(i), ub = uf(j);
					if (ua != ub) {
						ds[ub] = ua;
						sz[ua] += sz[ub];
					}
				}
			}
		}
		for (int i = 1; i <= n; i++)
			if (uf(i) == i)
				for (int j = 1; j <= sz[i]; j++)
					ans = (ans * j) % md;
		for (int i = 1; i <= n; i++)
			for (int j = 1; j <= n; j++)
				p[i][j] = tp[j][i];
	}
	cout << ans << '\n';
	return 0;
}

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

#define int long long

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

    map <int, set <int>> g ;

    int n, m ;
    cin >> n >> m ;
    for (int i=0;i<m;++i) {
        int a, b ; cin >> a >> b ;
        g[a].insert(b) ;
    }
    set <int> res ;
    res.insert(n) ;
    n += n ;
    for (auto r: g) {
        vector <int> add ;
        int y = r.first ;
        for (auto it: g[y]) {
            for (auto d:{1, -1}) {
                if (res.count(it+d)) add.push_back(it) ;
            }
        }
        for (auto it: g[y]) res.erase(it) ;
        for (auto it: add) res.insert(it) ;
    }
    cout << res.size() << endl ;
    return 0;
}


#include <iostream>
#include <cstdio>
#include <cstdlib>
#include <algorithm>
#include <cmath>
#include <vector>
#include <set>
#include <map>
#include <unordered_set>
#include <unordered_map>
#include <queue>
#include <ctime>
#include <cassert>
#include <complex>
#include <string>
#include <cstring>
#include <chrono>
#include <random>
#include <bitset>
using namespace std;

#ifdef LOCAL
	#define eprintf(...) fprintf(stderr, __VA_ARGS__);fflush(stderr);
#else
	#define eprintf(...) 42
#endif

using ll = long long;
using ld = long double;
using uint = unsigned int;
using ull = unsigned long long;
template<typename T>
using pair2 = pair<T, T>;
using pii = pair<int, int>;
using pli = pair<ll, int>;
using pll = pair<ll, ll>;
mt19937_64 rng(chrono::steady_clock::now().time_since_epoch().count());
ll myRand(ll B) {
	return (ull)rng() % B;
}

#define pb push_back
#define mp make_pair
#define all(x) (x).begin(),(x).end()
#define fi first
#define se second

clock_t startTime;
double getCurrentTime() {
	return (double)(clock() - startTime) / CLOCKS_PER_SEC;
}

const ll MOD = 998244353;
ll add(ll x, ll y) {
	x += y;
	if (x >= MOD) return x - MOD;
	return x;
}
ll sub(ll x, ll y) {
	x -= y;
	if (x < 0) return x + MOD;
	return x;
}
ll mult(ll x, ll y) {
	return (x * y) % MOD;
}
ll bin_pow(ll x, ll p) {
	if (p == 0) return 1;
	if (p & 1) return mult(x, bin_pow(x, p - 1));
	return bin_pow(mult(x, x), p / 2);
}
ll rev(ll x) {
	return bin_pow(x, MOD - 2);
}

const int N = 5050;
int C[N][N];
int dp[N];
int n, m;

int main()
{
	startTime = clock();
//	freopen("input.txt", "r", stdin);
//	freopen("output.txt", "w", stdout);

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

	for (int i = 0; i < N; i++)
		C[i][0] = C[i][i] = 1;
	for (int i = 1; i < N; i++)
		for (int j = 1; j < i; j++)
			C[i][j] = add(C[i - 1][j - 1], C[i - 1][j]);
	for (int k = 2; k <= n; k += 2)
		dp[k] = C[n][k];
	for (int x = 1; x < m; x++)
		for (int k = 0; 2 * x + k <= m && k <= n; k += 2)
			dp[2 * x + k] = add(dp[2 * x + k], mult(dp[x], C[n][k]));
	printf("%d\n", dp[m]);

	return 0;
}

#include <iostream>
using namespace std;
int main(){
   double a,b;
    cin>>a;
    cin>>b;
    double bKonprs = b / 100;
    cout<<a*bKonprs<<endl;
    return 0;
}


#include <bits/stdc++.h>

using namespace std;
typedef long long ll;
typedef pair<ll, ll> p_ll;

template<class T>
void debug(T itr1, T itr2) { auto now = itr1; while(now<itr2) { cout << *now << " "; now++; } cout << endl; }
#define repr(i,from,to) for (ll i=(ll)from; i<(ll)to; i++)
#define all(vec) vec.begin(), vec.end()
#define rep(i,N) repr(i,0,N)
#define per(i,N) for (ll i=(ll)N-1; i>=0; i--)

const ll MOD = pow(10,9)+7;
const ll LLINF = pow(2,61)-1;
const ll INF = pow(2,30)-1;

vector<ll> fac;
void c_fac(ll x=pow(10,7)+10) { fac.resize(x,true); rep(i,x) fac[i] = i ? (fac[i-1]*i)%MOD : 1; }
ll inv(ll a, ll m=MOD) { ll b = m, x = 1, y = 0; while (b!=0) { ll d = a/b; a -= b*d; swap(a,b); x -= y*d; swap(x,y); } return (x+m)%m; }
ll nck(ll n, ll k) { return fac[n]*inv(fac[k]*fac[n-k]%MOD)%MOD; }
ll modpow(ll x, ll p) { ll result = 1, now = 1, pm = x; while (now<=p) { if (p&now) { result = result * pm % MOD; } now*=2; pm = pm*pm % MOD; } return result; }
ll gcd(ll a, ll b) { if (a<b) swap(a,b); return b==0 ? a : gcd(b, a%b); }
ll lcm(ll a, ll b) { return a/gcd(a,b)*b; }

int main() {
  ll N, X; cin >> N >> X;
  ll V[N], P[N]; rep(i,N) cin >> V[i] >> P[i];

  X *= 100;
  ll sum = 0;
  rep(i,N) {
    sum += V[i] * P[i];
    if (sum>X) {
      cout << i+1 << endl;
      return 0;
    }
  }
  cout << -1 << endl;
  return 0;
}

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

const int N = 2e5 + 5, mod = 1e9 + 7;
char s[N];
int a[N], k;
int add (int a, int b) {
	return ((a += b) >= mod) ? (a - mod) : a;
}
int dp[N][20], K;
int f (int l, int k) {
	if (~dp[l][k]) return dp[l][k];
	if (l == 0) return k == K;
	dp[l][k] = (ll)k * f(l - 1, k) % mod;
	if (k)
		dp[l][k] = add(dp[l][k], (ll)f(l - 1, k + 1) * (16 - k) % mod);
	return dp[l][k];
}
int main() {
	memset (dp, -1, sizeof (dp));
	cin >> (s + 1) >> K;
	int len = strlen(s + 1);
	for (int i = 1; i <= len; ++i) {
		if (isdigit(s[i])) a[i] = s[i] - '0';
		else a[i] = s[i] - 'A' + 10;
	}

	int ans = 0;
	for (int i = len; i >= 2; --i) {
		for (int j = 1; j < 16; ++j) ans += f (len - i, 1), ans %= mod;
		ans %= mod;
	}

//	cerr << ans << '\n';
	int st = 0;
	for (int i = 1; i <= len; ++i) {
		for (int j = ((i == 1) ? 1 : 0); j < a[i]; ++j) {
			int newst = st | (1 << j), cnt = __builtin_popcount(newst);
		//	cerr << len - i << " " << cnt << ":" << f(len - i, cnt) << '\n';
			ans = add(ans, f(len - i, cnt));
		}
		st |= (1 << a[i]);
	}
	if (__builtin_popcount(st) == K) ans = add(ans, 1);
	cout << ans << '\n';
	return 0;
}


#include <bits/stdc++.h>

using namespace std;

#define int long long
#define pi pair<int,int>
#define pb(x) push_back(x)
#define ff first
#define ss second
#define all(x) x.begin(), x.end()
#define dbg(x) cout << #x << ": " << x << "\n"
#define dbg2(x, y) cout <<"{ " << #x  <<", "<< #y<< " }"<< ": " <<"{ " << x  <<", "<< y<< " }" << "\n"
const int MAX_N = 1e5 + 1;
const int MOD = 1e9 + 7;
const int INF = 1e18;

void dfs(int st, int i, vector<int> adj[], vector<bool>& vis, vector<vector<int>>& poss){
	if(vis[i]) return;
	vis[i] = true;
	poss[st][i] = true;
	for(int j: adj[i]){
		dfs(st, j, adj, vis, poss);
	}
}

void solve() {
	int n, m; cin >> n >> m;
	vector<int> adj[n];
	vector<vector<int>> poss(n, vector<int>(n, 0));
	for(int i = 0; i < m; i++){
		int u, v; cin >> u >> v;
		u--; v--;
		adj[u].push_back(v);
	}
	for(int i = 0; i < n; i++){
		vector<bool> vis(n, false);
		dfs(i, i, adj, vis, poss);
	}
	int ans = 0;
	for(auto x: poss){
		for(auto y: x){
			ans += y;
		}
	}
	cout << ans << "\n";
}

int32_t main() {
    ios_base::sync_with_stdio(0);
    cin.tie(0); cout.tie(0);
    int tc = 1;
    // cin >> tc;
    for (int t = 1; t <= tc; t++) {
        solve();
    }
}

#include <bits/stdc++.h>

#define INF 1e9
#define LINF (1LL << 63 - 1)
#define rep(i,n)for(int i=0;(i)<(int)(n);i++)
#define REP(i,a,b)for(int i=(int)(a);(i)<=(int)(b);i++)
#define ALL(a)  (a).begin(),(a).end()
// #define chmax(a, b) a = max(a, b)
// #define chmin(a, b) a = min(a, b)
#define pb push_back
#define fi first
#define se second
#define sz(x) ((int)x.size())

using namespace std;
//using namespace atcoder;
using ld = long double;
using ll = long long;
using P = pair<ll, ll>;

template<typename T> bool chmin(T& a, const T& b) { if(a > b){ a = b; return 1;} return 0; }
template<typename T> bool chmax(T& a, const T& b) { if(a < b){ a = b; return 1;} return 0; }

const ll ZER = 0;
const ll MOD = 1e9 + 7;

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

    int h, w;
    cin >> h >> w;
    ll sum = 0, mi = INF * INF;
    vector<vector<ll>> s(h, vector<ll> (w));
    rep(i, h)rep(j, w)cin >> s[i][j];
    rep(i, h){
        rep(j, w){
            chmin(mi, s[i][j]);
        }
    }
    rep(i, h){
        rep(j, w){
            sum += s[i][j] - mi;
        }
    }
    cout << sum << endl;
}


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

int main() {
  std::string str; std::cin >> str;
  std::vector<int> v, mod;
  int sum = 0;
  for (int i = 0; i < str.length(); ++i) {
    v.push_back(str[i] - '0');
    sum += v[i];
    if (v[i] % 3) mod.push_back(v[i] % 3);
  }

  std::sort(mod.begin(), mod.end());
  int ans = -1;

  if (sum % 3 == 0) ans = 0;
  else if (!mod.empty()) {
    if (sum % 3 == 1) {
      if (mod[0] == 1) {
	ans = 1;
      } else if (mod.size() > 1 && mod[mod.size() - 2] == 2) {
	ans = 2;
      }
    } else {
      if (mod[mod.size() - 1] == 2) {
	ans = 1;
      } else if (mod.size() > 1) {
	ans = 2;
      }
    }
  }

  if (ans == str.length()) ans = -1;

  std::cout << ans << std::endl;
  return 0;
}

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

typedef long long int ll;
typedef pair<ll, ll> p_ll;
typedef vector<pair<ll, ll>> vec_p; //vector<pair<ll, ll>> pairs(n) ,pairs.at(i) = make_pair(i*i, i)

#define ture ture
#define flase false
#define falg flag

#define REP(i, x) for (ll i = 0; i < (ll)(x); i++)
#define REPS(i, x) for (ll i = 1; i <= (ll)(x); i++)
#define RREP(i, x) for (ll i = ((ll)(x)-1); i >= 0; i--)
#define RREPS(i, x) for (ll i = ((ll)(x)); i > 0; i--)
#define all(x) (x).begin(), (x).end()

const ll MOD = pow(10, 9) + 7;
const ll LLINF = pow(2, 61) - 1;//llの最大9*10^18
const int INF = pow(2, 30) - 1;

ll gcd(ll a, ll b) { return b ? gcd(b, a % b) : a; }

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

    ll N;
    string S;
    cin >> S;
    vector<ll> A(S.size());
    bool flag = false;
    ll ans = 10000000000000;

    REP(i,S.size()){
        A.at(i) = S.at(i) - '0';
    }

    ll b = A.size();

    for (int bit = 0; bit <= (1 << S.size()); ++bit)
    {

        ll tmp = 0;
        ll tmp1 = 0;

        for (int i = 0; i < S.size(); ++i)
        {

            if (bit & (1 << i))
            { // 列挙に i が含まれるか
                tmp += A.at(i);
                tmp1++;
            }

        }
        if (tmp % 3 == 0 && tmp > 0)
        {
            flag = true;
            ans = min(ans, b - tmp1);
        }

        //cout << bit << " " << b - tmp1 << endl;
        tmp = 0;
        tmp1 = 0;
    }

    if(flag){
        cout << ans << endl;
    }
    else{
        cout << -1 << endl;
    }
}


/* How To Solve It
 1st. Understanding The Problem
    未知なもの、データ(与件), 条件 は何か？
    その条件は未知を決定するために十分か？
    条件を分解せよ, 図を描け
 2nd. Devising A Plan
    類似、関連のある問題、典型問題を知らないか？
    役立ちそうな定理やアルゴリズムを知らないか？
    問題の一部を解決できるか、一部だけ残して他を切り捨ててみろ
    既知のものやデータを変えることはできるか？
 3rd. Carrying Out The Plan
    各ステップで誤りがないか、正しいと説明できるか？
 4th. Looking Back
    別解、他の問題に使えそうなものはあるか？
*/
/*{{{ #include */
#include <iostream>
#include <cstdio>
#include <string>
#include <vector>
#include <set>
#include <queue>
#include <stack>
#include <map>
#include <tuple>
#include <algorithm>
#include <utility>
#include <cmath>/*}}}*/
/*{{{ namespace R2357 */
namespace R2357 {
    inline void IN(void){return;}
    template<class F,class... R>inline void IN(F& f,R&... r){std::cin>>f;IN(r...);}
    template <class T>inline void OUT(T x){std::cout<<x<<'\n';}
    template<class T>inline bool chmin(T& a,T b){if(a>b){a=b;return 1;}return 0;}
    template<class T>inline bool chmax(T& a,T b){if(a<b){a=b;return 1;}return 0;}
    template<class T=int>T read(){
        T x=0; char c;
        while(((c=getchar())>'9'||c<'0')&&c!='-');
        const bool f=(c=='-')&&(c=getchar());
        while(x=x*10-48+c,(c=getchar())>='0'&&c<='9');
        return f?-x:x;
    }
    template<class T>std::istream& operator>>(std::istream& is,std::vector<T>& V){
        for(auto& v:V)is>>v; return is;
    }
    template<class T1,class T2>
    std::istream& operator>>(std::istream& is,std::pair<T1,T2>& P){
        return is>>P.first>>P.second;
    }
    template<class T>inline T ceil_div(T a,T b){
    	return (a+(b-1))/b;
    }
    namespace debug {
        using namespace std;
        void Write(void){cerr<<endl;}
        template<class F,class...R>void Write(F f,R...r){cerr<<' '<<f;Write(r...);}
        template<class T>void Write(vector<T>& V,int n=-1){
            if(n==-1) n = V.size();
            for(int i=0;i<n;i++)cerr<<' '<<V[i]; cerr<<endl;
        }
        template<class T,class U> void Write(pair<T,U>& p){cerr<<' '<<'{'<<p.first<<','<<p.second<<'}'<<endl;}
        #include <cxxabi.h>
        template<class T>string TypeName(T& x){
            return string(abi::__cxa_demangle(typeid(T).name(), 0, 0, 0));
        }
    }
}/*}}}*/
/*{{{ using */
using namespace std; using namespace R2357;
using ll=long long; using ld=long double;
using pint=pair<int,int>;/*}}}*/
/*{{{ #define */
#define rep(i,a,b) for(ll i=a;i<ll(b);i++)
#define repr(i,a,b) for(ll i=a;i>=ll(b);i--)
#define each(x,v) for(auto& x:v)
#define el '\n'
#define ALL(x) x.begin(),x.end()
#define ALLR(x) x.rbegin(),x.rend()
#define Unique(x) sort(x.begin(),x.end());x.erase(unique(x.begin(),x.end()),x.end())
#define Fill(v,n) fill(v,v+sizeof(v)/sizeof(*v),n)
#define max_element(x) *max_element(x.begin(),x.end())
#define min_element(x) *min_element(x.begin(),x.end())
#define INF 1073741824 // 2e30
#define INFL 2305843009213693952ll // 2e61
#define _FASTIO_ ios::sync_with_stdio(false),cin.tie(nullptr);
/*}}}*/

/* NOTE
 0.
*/
// using namespace debug;

int main(){ _FASTIO_
    int a, b; IN(a, b);
    if(abs(a-b) < 3) OUT("Yes");
    else OUT("No");
    return 0;
}

#include <bits/stdc++.h>
#define fi first
#define se second
#define o2(x) (x) * (x)
#define mk make_pair
#define eb emplace_back
#define SZ(x) ((int)(x).size())
#define all(x) (x).begin(), (x).end()
#define clr(a, b) memset((a), (b), sizeof((a)))
#define rep(i,s,t) for(register int i=s;i<t;++i)
#define per(i,s,t) for(register int i=s;i>=t;--i)
#define GKD std::ios::sync_with_stdio(false);cin.tie(0)
#define my_unique(x) sort(all(x)), x.erase(unique(all(x)), x.end())
using namespace std;
typedef long long LL;
typedef long long int64;
typedef unsigned long long uint64;
typedef pair<int, int> pii;
// mt19937 rng(time(NULL));
// mt19937_64 rng64(chrono::steady_clock::now().time_since_epoch().count());
// mt19937_64 generator(std::clock());
// shuffle(arr, arr + n, generator);
inline int64 read() {
    int64 x = 0;int f = 0;char ch = getchar();
    while (ch < '0' || ch > '9') f |= (ch == '-'), ch = getchar();
    while (ch >= '0' && ch <= '9') x = (x << 3) + (x << 1) + ch - '0', ch =
    getchar(); return x = f ? -x : x;
}
inline void write(int64 x, bool f = true) {
    if (x == 0) {putchar('0'); if(f)putchar('\n');else putchar(' ');return;}
    if (x < 0) {putchar('-');x = -x;}
    static char s[23];
    int l = 0;
    while (x != 0)s[l++] = x % 10 + 48, x /= 10;
    while (l)putchar(s[--l]);
    if(f)putchar('\n');else putchar(' ');
}
int lowbit(int x) { return x & (-x); }
template <class T>
T big(const T &a1, const T &a2) {return a1 > a2 ? a1 : a2;}
template <class T>
T sml(const T &a1, const T &a2) {return a1 < a2 ? a1 : a2;}
template <typename T, typename... R>
T big(const T &f, const R &... r) {return big(f, big(r...));}
template <typename T, typename... R>
T sml(const T &f, const R &... r) {return sml(f, sml(r...));}
void debug_out() { cout << '\n'; }
template <typename T, typename... R>
void debug_out(const T &f, const R &... r) {
    cout << f << " ";
    debug_out(r...);
}
#ifdef LH_LOCAL
#define debug(...) cout << "[" << #__VA_ARGS__ << "]: ", debug_out(__VA_ARGS__);
#else
#define debug(...) ;
#endif
/*================Header Template==============*/
const int INF = 0x3f3f3f3f;
const int mod = 998244353;// 998244353
const int MXN = 1500 + 5;
const int MXE = 2e6 + 5;
int n, m, h, w;
int mp[MXN][MXN];
vector<pii> col[MXN], row[MXN];
int main() {
#ifdef LH_LOCAL
    freopen("D:in.txt", "r", stdin);
    //freopen("D:out.txt", "w", stdout);
#endif
    n = read(), m = read(), h = read(), w = read();
    rep(i, 0, h) {
        int x = read(), y = read();
        row[x].eb(mk(y, 1));
        col[y].eb(mk(x, 1));
        mp[x][y] = 1;
    }
    rep(i, 0, w) {
        int x = read(), y = read();
        row[x].eb(mk(y, -1));
        col[y].eb(mk(x, -1));
        mp[x][y] = -1;
    }
    rep(i, 1, n + 1) sort(all(row[i]));
    rep(j, 1, m + 1) sort(all(col[j]));
    int ans = 0;
    rep(i, 1, n + 1) {
        rep(j, 1, m + 1) {
            if(mp[i][j] == 1) ++ ans;
            if(mp[i][j]) continue;
            int flag = 0;
            ans += flag;
            pii tmp = mk(j, 0);
            int p = lower_bound(all(row[i]), tmp) - row[i].begin();
            if(p < (int)row[i].size() && row[i][p].se == 1) flag = 1;
            -- p;
            if(p >= 0 && p < (int)row[i].size() && row[i][p].se == 1) flag = 1;
            tmp = mk(i, 0);
            p = lower_bound(all(col[j]), tmp) - col[j].begin();
            if(p < (int)col[j].size() && col[j][p].se == 1) flag = 1;
            -- p;
            if(p >= 0 && p < (int)col[j].size() && col[j][p].se == 1) flag = 1;
            ans += flag;
        }
    }
    printf("%d\n", ans);
#ifdef LH_LOCAL
    cout << "time cost:" << 1.0 * clock() / CLOCKS_PER_SEC << "s" << endl;
    // system("pause");
#endif
    return 0;
}


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

#define ll long long int
#define pb push_back
#define Messi ios::sync_with_stdio(0);cin.tie(0);cout.tie(0);
#define pii pair<pair<ll,ll>, ll>
#define mod 1000000007
#define vi vector<ll>
#define vii vector<pii>
#define all(v) v.begin(),v.end()
#define mi map<ll, ll>
//Never Let U Go!!

int main()
{
    Messi;
    ll n;
    cin>>n;
    vector<pii>v;
    for(ll i=0;i<n;i++)
    {
        ll a,b,c;
        cin>>a>>b>>c;
        v.pb({{a,c},b});
    }
    ll ans=LONG_MAX;
    for(auto g:v)
    {
        ll t= g.first.first;
        if(t<g.first.second)
           ans=min(ans,g.second);
    }
    if(ans==LONG_MAX)
    cout<<"-1";
    else
    cout<<ans;
    return 0;
}

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

int main(){
int n;
cin >> n;
vector<string> s(n);
set<string> st;
for(int i=0;i<n;i++){
    cin >> s[i];
    st.insert(s[i]);
}
for(int i=0;i<n;i++){
    if(s[i][0]!='!'){
        if(st.count('!'+s[i])>=1){
            cout << s[i] << endl;
            return 0;
        }
    }
}
cout << "satisfiable" << endl;

}


#include <bits/stdc++.h>
using namespace std;
#define FASTIO cin.tie(0);ios::sync_with_stdio(0)

int main() {
	FASTIO;
	string n;
	cin >> n;
	map<char, int> ava;
	for (int i = 0; i < n.size(); i++) {
		ava[n[i]]++;
	}
	if (n.size() >= 3) {
		for (int i = 104; i < 1000; i+=8) {
			string mystring = to_string(i);
			int c = 0;
			map<char, int> need;
			for (char i : mystring) {
				need[i]++;
			}
			for (auto pair : need) {
				if (ava[pair.first] >= pair.second) {
					c += pair.second;
				}
			}
			if (c == 3) {
				cout << "Yes" << "\n";
				return 0;
			}
		}
		cout << "No" << "\n";
	} else if (n.size() == 2) {
		for (int i = 16; i < 100; i+=8) {
			string mystring = to_string(i);
			int c = 0;
			map<char, int> need;
			for (char i : mystring) {
				need[i]++;
			}
			for (auto pair : need) {
				if (ava[pair.first] >= pair.second) {
					c += pair.second;
				}
			}
			if (c == 2) {
				cout << "Yes" << "\n";
				return 0;
			}
		}
		cout << "No" << "\n";
	} else {
		if (ava['8'] == 1) {
			cout << "Yes" << "\n";
			return 0;
		} else {
			cout << "No" << "\n";
			return 0;
		}
	}
}

#include <bits/stdc++.h>
#define rep(i,n) for(int i = 0; i < (n); i++)
using namespace std;
using ll = long long;
using P = pair<int,int>;

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

    string s;
    cin >> s;

    vector<int> cnt(10);
    int n = s.size();

    if(n == 1){
        if(s == "8") cout << "Yes" << endl;
        else cout << "No" << endl;
        return 0;
    }

    if(n == 2){
        int num = (s[0]-'0')*10 + s[1];
        if(num % 8 == 0){
            cout << "Yes" << endl;
            return 0;
        }
        num = (s[1]-'0')*10 + s[0];
        if(num % 8 == 0){
            cout << "Yes" << endl;
            return 0;
        }
        cout << "No" << endl;
        return 0;
    }

    rep(i,n){
        cnt[s[i]-'0']++;
    }

    rep(i,10){
        rep(j,10){
            rep(k,10){
                if(!i || !j || !k) continue;
                vector<int> c = cnt;
                c[i]--, c[j]--, c[k]--;
                bool flag = false;
                rep(l,10){
                    if(c[l] < 0)flag = true;
                }
                if(flag) continue;

                int num = i*100 + j*10 + k;
                if(num % 8 == 0){
                    cout << "Yes" << endl;
                    return 0;
                }
            }
        }
    }
    cout << "No" << endl;
}


#include <iostream>
#include <vector>
using namespace std;

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

  vector<int> v(n);
  for(auto& nx : v) {
    cin >> nx;
  }

  bool b = 0;
  for(int i = 0; i < n; ++i) {
    for(int j = i + 1; j < n; ++j) {
      if(v[i] == v[j]) {
        cout << "No" << endl;
        b = 1;
        break;
      }
    }
    if(b == 1) break;
  }

  if(b == 0) {
    cout << "Yes" << endl;
  }

  return 0;
}

// #include <atcoder/all>
#include <bits/stdc++.h>

#ifndef M_PI
#define M_PI 3.14159265358979
#endif
#define deg_to_rad(deg) (((deg) / 360) * 2 * M_PI)
#define rad_to_deg(rad) (((rad) / 2 / M_PI) * 360)

#define rep2(i, m, n) for(long long i = (m); i < (n); ++i)
#define rep(i, n) rep2(i, 0, n)
#define drep2(i, m, n) for(long long i = (m)-1; i >= (n); --i)
#define drep(i, n) drep2(i, n, 0)
#define all(x) (x).begin(), (x).end()

using namespace std;
// using namespace atcoder;

typedef long long ll;
typedef vector<ll> vll;
typedef vector<int> vi;
typedef pair<ll, ll> pll;
typedef pair<int, int> pi;
typedef long double ld;
typedef pair<long double, long double> pld;

template <class T> bool chmax(T &a, const T &b) {
    if(a < b) {
        a = b;
        return 1;
    }
    return 0;
}
template <class T> bool chmin(T &a, const T &b) {
    if(b < a) {
        a = b;
        return 1;
    }
    return 0;
}

const ll INF = 1e18;
const ll MOD = 1e9 + 7;
// const ll MOD = 998244353;

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

    ll N;
    cin >> N;
    vll A(N);
    for(auto &e : A)
        cin >> e;
    vll P(N, 0);
    rep(i, N) {
        ll a = --A[i];
        P[a]++;
    }
    ll ok = 1;
    rep(i, N) {
        if(P[i] != 1)
            ok = 0;
    }
    if(ok == 1) {
        cout << "Yes" << endl;
    } else {
        cout << "No" << endl;
    }

    return 0;
}


#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < int(n); i++)
using namespace std;
using ll = long long;
const int INF = (1<<30)-1;
const long long LINF = (1LL<<62)-1;
const int dx[] = {-1, 0, 1, 0};
const int dy[] = {0, 1, 0, -1};
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; }

signed main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  string s;
  cin >> s;
  map<int, int> mp;
  rep(i, s.size()) mp[s[i]-'0']++;
  rep(i, 1000) {
    if (i%8)
      continue;
    vector<int> num(10);
    int tmp = i;
    rep(_, min(3, (int)s.size())) {
      num[tmp%10]++;
      tmp /= 10;
    }
    bool flag = true;
    rep(i, 10) {
      if (mp[i] < num[i])
        flag = false;
    }
    if (flag) {
      cout << "Yes\n";
      return 0;
    }
  }
  cout << "No\n";
  return 0;
}

#include <iostream>
#include <cstdio>
#include <algorithm>
#include <cstring>
#include <queue>
#include <map>
#include <unordered_map>
using namespace std;

#define debug(x) cout << #x << '=' << x << '\n'
#define rep(i, b, e) for (int i = b; i <= e; i++)

const int N = 212345;

int n, a[N], b[N], c[N];
unordered_map<int, queue<int>> mp;

struct BIT {
    int c[N], size;
    inline int lowbit(const int &x) {
        return x & (-x);
    }
    inline void add(int loc, const int &val) {
        for (; loc <= size; loc += lowbit(loc)) {
            c[loc] += val;
        }
    }
    inline int query(int loc) {
        int ret = 0;
        for (; loc; loc -= lowbit(loc)) {
            ret += c[loc];
        }
        return ret;
    }
} Bit;

int main(){
    cin >> n;
    rep (i, 1, n) {
        scanf("%d", a + i);
        a[i] += i;
        mp[a[i]].push(i);
    }
    rep (i, 1, n) {
        scanf("%d", b + i);
        b[i] += i;
        if (mp[b[i]].size() == 0) {
            puts("-1");
            return 0;
        }
        c[i] = mp[b[i]].front();
        mp[b[i]].pop();
    }
    //rep (i, 1, n) {
    //    debug(c[i]);
    //}
    Bit.size = n;
    long long ans = 0;
    for (int i = n; i > 0; i--) {
        ans += Bit.query(c[i] - 1);
        Bit.add(c[i], 1);
    }
    cout << ans;
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
#define fast_io cin.tie(0);ios_base::sync_with_stdio(0);
string to_string(string s) { return '"' + s + '"';}
string to_string(char s) { return string(1, s);}
string to_string(const char* s) { return to_string((string) s);}
string to_string(bool b) { return (b ? "true" : "false");}
template <typename A> string to_string(A);
template <typename A, typename B>string to_string(pair<A, B> p) {return "(" + to_string(p.first) + ", " + to_string(p.second) + ")";}
template <typename A> string to_string(A v) {bool f = 1; string r = "{"; for (const auto &x : v) {if (!f)r += ", "; f = 0; r += to_string(x);} return r + "}";}
void debug_out() { cout << endl; }
void show() { cout << endl; }
void pret() { cout << endl; exit(0);}
template <typename Head, typename... Tail> void debug_out(Head H, Tail... T) {cout << " " << to_string(H); debug_out(T...);}
template <typename Head, typename... Tail> void show(Head H, Tail... T) {cout <<H<<" "; show(T...);}
template <typename Head, typename... Tail> void pret(Head H, Tail... T) {cout <<H<<" "; pret(T...);}
#define pr(...) cout << "[" << #__VA_ARGS__ << "]:", debug_out(__VA_ARGS__)
typedef long long ll;
// #define int ll
typedef long double ld;
typedef vector<int> vi;
#define disp(x) cout<<x<<" ";
#define rep(i,a,b) for(int i=a;i<(int)b;i++)
#define fo(i,a,b) for(int i=a;i<=(int)b;i++)
#define rf(i,a,b) for(int i=a;i>=(int)b;i--)
#define mp make_pair
#define pb emplace_back
#define F first
#define S second
#define endl '\n'
//cout.setf(ios::fixed);cout.precision(18)
const int MOD = 998244353;
const int maxn = 2e5+10;

ll factorial[maxn], inverse[maxn];

ll power(ll a, ll b){
    ll x = 1, y = a;
    while (b > 0){
        if (b%2){
            x = (x*y)%MOD;
        }
        y = (y*y)%MOD;
        b /= 2;
    }
    return x%MOD;
}

ll modular_inverse(ll n){
    return power(n, MOD-2);
}

ll nCr(ll n, ll k){
	if(n < k) return 0;
    ll flag= ((factorial[n])*(modular_inverse(factorial[k])))%MOD;
    return (flag*modular_inverse(factorial[n-k]))%MOD;
}

void add(int &a, int b){
	a += b;
	if(a >= MOD) a -= MOD;
	if(a < 0) a += MOD;
}

const int lognum = 19;

int dp[maxn][lognum];

int f(){
	int n, m;
	cin >> n >> m;
	fo(i, 1, m) dp[i][1] = 1;
	int ans = m;
	fo(j, 2, lognum - 1){
		if(j > n) break;
		// vector < bool > visited(m + 1, 0);
		int curr = 0;
		fo(i, 1, m){
			if(dp[i][j - 1] == 0) continue;
			for(int k = i + i; k <= m; k += i){
				add(dp[k][j], dp[i][j - 1]);
			}
		}
		fo(i, 2, m){
			add(curr, dp[i][j]);
		}
		// show(j, curr, nCr(n - 1, j - 1));
		add(ans, (ll(curr) * nCr(n - 1, j - 1)) % MOD);
	}
	return ans;
}

int32_t main(){
    fast_io;
    int t = 1;
    factorial[0] = 1;
    // inverse[0] = 1;
    fo(i, 1, maxn - 1){
    	factorial[i] = (factorial[i - 1] * i) % MOD;
    	// inverse[i] = modular_inverse(factorial[i]);
    }
    // cin>>t;
    while(t--){
    	show(f());

    	// f();

    	// if(f()){
    	// 	cout<<"YES"<<endl;
    	// }
    	// else cout<<"NO"<<endl;
    }
    return 0;
}

#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
using namespace std;
#ifdef ENABLE_DEBUG
#define dump(a) cerr<<#a<<"="<<a<<endl
#define dumparr(a,n) cerr<<#a<<"["<<n<<"]="<<a[n]<<endl
#else
#define dump(a)
#define dumparr(a,n)
#endif
#define FOR(i, a, b) for(ll i = (ll)a;i < (ll)b;i++)
#define For(i, a) FOR(i, 0, a)
#define REV(i, a, b) for(ll i = (ll)b-1LL;i >= (ll)a;i--)
#define Rev(i, a) REV(i, 0, a)
#define REP(a) For(i, a)
#define SIGN(a) (a==0?0:(a>0?1:-1))

typedef long long int ll;
typedef unsigned long long ull;
typedef unsigned int uint;
typedef pair<ll, ll> pll;
typedef pair<ll,pll> ppll;
typedef vector<ll> vll;
typedef long double ld;
typedef pair<ld,ld> pdd;

pll operator+(pll a,pll b){
  return pll(a.first+b.first,a.second+b.second);
}
pll operator-(pll a,pll b){
  return pll(a.first-b.first,a.second-b.second);
}
pll operator*(ll a,pll b){
  return pll(b.first*a,b.second*a);
}
const ll INF=(1LL<<60);
#if __cplusplus<201700L
ll gcd(ll a, ll b) {
  a=abs(a);
  b=abs(b);
  if(a==0)return b;
  if(b==0)return a;
  if(a < b) return gcd(b, a);
  ll r;
  while ((r=a%b)) {
    a = b;
    b = r;
  }
  return b;
}
#endif
template<class T>
bool chmax(T& a,const T& b){
  if(a<b){
    a=b;
    return true;
  }
  return false;
}
template<class T>
bool chmin(T& a,const T& b){
  if(a>b){
    a=b;
    return true;
  }
  return false;
}
template<class S,class T>
std::ostream& operator<<(std::ostream& os,pair<S,T> a){
  os << "(" << a.first << "," << a.second << ")";
  return os;
}
template<class T>
std::ostream& operator<<(std::ostream& os,vector<T> a){
  os << "[ ";
  REP(a.size()){
    os<< a[i] << " ";
  }
  os<< " ]";
  return os;
}

const long long MOD = 998244353;
const long long max_cache=1000000;
long long cache_fact[max_cache],cache_inv_fact[max_cache];
long long combination_cached(long long n,long long r){
  ll m=MOD;
  static bool cached=false;
  if(cached==false){
    cached=true;
    cache_inv_fact[1]=1;
    for (long long i = 2; i < max_cache; i++) {
      cache_inv_fact[i]=(m-m/i)*cache_inv_fact[m%i]%m;
    }
    for (long long i = 2; i < max_cache; i++){
      cache_inv_fact[i]=cache_inv_fact[i]*cache_inv_fact[i-1]%m;
    }
    cache_fact[0]=1;
    for (long long i = 1; i < max_cache; i++) {
      cache_fact[i]=cache_fact[i-1]*i%m;
    }
  }
  if(r<0||r>n)return 0;
  if(r==0||r==n)return 1;
  if(n>m){
    std::cerr<<"Combination Error: n is greater than m"<<std::endl;
    exit(1);
  }
  r=min(r,n-r);
  return cache_fact[n]*cache_inv_fact[r]%m*cache_inv_fact[n-r]%m;
}
long long homogeneous(long long n,long long r){
  return combination_cached(n+r-1,r);
}
void solve(long long N, long long M){
  if(N==1){
    cout<<M<<endl;
    return;
  }
  vector<ll> primes{2};
  for (ll i = 3; i*i <= M; i+=2)
  {
    bool f=true;
    for (auto &&j : primes)
    {
      if(i%j==0){
        f=false;
        break;
      }
    }
    if(f){
      primes.push_back(i);
    }
  }
  ll ans=0;
  FOR(i,1,M+1){
    ll cur=i;
    vector<ll> cnts;
    for (auto &&p : primes)
    {
      ll cnt=0;
      while(cur%p==0){
        ++cnt;
        cur/=p;
      }
      if(cnt>0){
        cnts.push_back(cnt);
      }
    }
    if(cur>1){
      cnts.push_back(1);
    }
    ll curans=1;
    for (auto &&j : cnts)
    {
      curans*=homogeneous(N,j);
      curans%=MOD;
    }
    dump(i);
    dump(curans);
    ans=(ans+curans)%MOD;
  }
  cout<<ans<<endl;
  return;
}

int main(){
  cout<<setprecision(1000);
  long long N;
    scanf("%lld",&N);
    long long M;
    scanf("%lld",&M);
  solve(N, M);
  return 0;
}


//#pragma GCC optimize ("O3","unroll-loops")
#include<iostream>
#include<iomanip>
#include<cstdio>
#include<cstdlib>
#include<cassert>

#include<cmath>
#include<functional>
#include<algorithm>
#include<numeric>

#include<vector>
#include<string>
#include<queue>
#include<stack>
#include<deque>
#include<set>
#include<map>
#include<bitset>
#include<tuple>

#define TEST {IS_TEST=true;}
#define fi first
#define se second
#define pb(x) emplace_back(x)
#define pf(x) emplace_front(x)
#define emp(x) emplace(x)
#define mp(x,y) make_pair(x,y)

using namespace std;
using ll = int_fast64_t;
using v_b = vector <bool>; using v_ll = vector <ll>; using str = string; using v_str = vector <string>; using p_ll = pair < ll,ll >;
using vv_b = vector < v_b >; using vv_ll = vector < v_ll >; using vp_ll = vector < p_ll >;
using vvv_ll = vector < vv_ll >; using vvp_ll = vector < vp_ll >;
using ld = long double; using v_ld = vector <ld>; using vv_ld = vector<v_ld>;

bool IS_TEST=false;
ll ll_min64=1LL<<63;
ll ll_max64=~ll_min64;
ll ll_min32=1LL<<31;
ll ll_max32=~ll_min32;

/*displaying functions for debug*/
template<class T> void show2(const T &x){cerr << x;}
template<class T1,class T2> void show2(const pair<T1,T2> &x){
  cerr << "{" << show2(x.first) << "," << show2(x.second) << "}";
}
template<class T> void show(const T &x){
  if (!IS_TEST) return; show2(x); cerr << "\n";
}
template<class T> void v_show(const T &v, ll n=-1){
  if (!IS_TEST) return; auto itr=v.begin(); ll m=n;
  while(itr!=v.end() && m!=0 ){ show2(*itr); cerr << " "; itr++; m--;}
  cerr << "\n";
}
template<class T> void vv_show(const T &v, ll n=-1){
  if (!IS_TEST) return;
  cerr << "--------------------------------\n";
  auto itr=v.begin(); ll m=n;
  while(itr!=v.end() && m!=0 ){ v_show(*itr,n); itr++; m--;}
  cerr << "--------------------------------\n";
}

ll max(ll x,ll y){return x>y?x:y;}
ll min(ll x,ll y){return x<y?x:y;}
template<class T> bool chmax(T& x,const T& y){ if (x>=y) return false; x=y; return true;}
template<class T> bool chmin(T& x,const T& y){ if (x<=y) return false; x=y; return true;}
template<class T> void quit(T x){cout << x << endl; exit(0);}

ll roundup(ll x,ll y){return (x-1)/y+1;}
ll remain(ll x,ll y){ ll z=x%y; return z>=0?z:z+y; }

v_ll idx_vector(ll n){
  v_ll ret(n,0);
  for(ll i=0;i<n;i++) ret[i]=i;
  return ret;
}

//setprecision(12)
//sort(##.begin(),##.end(),[&](auto &x, auto &y){if (x<y) return true;});
//ll ok=0,ng=0; while(abs(ok-ng)>1){ll mid=(ok+ng)/2; ( func(mid) ?ok:ng)=mid;}

// struct dat{
//     dat(){}
//     bool operator < (const dat& rhs)const {return false; }
// };
string el = "\n";
int main(){
  cin.tie(nullptr);
  ios::sync_with_stdio(false);
  ll A,B;
  cin >> A>> B;
  if (A>=B){
    ll sum = 0;
    for(ll i=0;i<A;i++){
      cout << (i+1) << " ";
      sum+=(i+1);
    }
    for(ll i=0;i<B-1;i++){
      cout << (-i-1) << " ";
      sum-=(i+1);
    }
    cout << (-sum) << "\n";
  }else{
    ll sum = 0;
    for(ll i=0;i<A-1;i++){
      cout << (i+1) << " ";
      sum+=(i+1);
    }
    for(ll i=0;i<B;i++){
      cout << (-i-1) << " ";
      sum-=(i+1);
    }
    cout << (-sum) << "\n";
  }
}

#include<bits/stdc++.h>
#define rep(i, n) for(int i = 0; i < n; ++i)
#define rrep(i, n) for(int i = n-1; i >= 0; --i)
#define fi first
#define se second
using namespace std;
using ll = long long;
using ui = unsigned int;
using ul = unsigned long long;
using ld = long double;
using v1i = vector<int>;
using v1ll = vector<ll>;
using v2i = vector<vector<int>>;
using v2ll = vector<vector<ll>>;
using v3i = vector<vector<vector<int>>>;
using v3ll = vector<vector<vector<ll>>>;
using v1b = vector<bool>;
using v2b = vector<vector<bool>>;
using v3b = vector<vector<vector<bool>>>;
using v1c = vector<char>;
using v2c = vector<vector<char>>;
using v3c = vector<vector<vector<char>>>;
constexpr ll MOD = 1000000007;
constexpr ll MOD2 = 998244353;

int main(){
    int n, k, m, ng = -1, ok = 1000000000; cin >> n >> k;
    m = k * k / 2;
    v2i v(n, v1i(n));
    v2i dp(n+1, v1i(n+1, 0));
    rep(i, n) rep(j, n) cin >> v[i][j];
    while(ok-ng > 1) {
        rep(i, n+1) dp[i].resize(n+1, 0);
        int c = (ng + ok) / 2;
        rep(i, n) {
            rep(j, n) {
                dp[i+1][j+1] = dp[i+1][j] + dp[i][j+1] - dp[i][j];
                if(v[i][j] > c) ++dp[i+1][j+1];
            }
        }
        bool b = 0;
        rep(i, n-k+1) rep(j, n-k+1) if(dp[k+i][k+j] + dp[i][j] - dp[k+i][j] - dp[i][k+j] <= m) b = 1;
        if(b) ok = c;
        else ng = c;
    }
    cout << ok << "\n";
    return 0;
}


#include<iostream>
using namespace std;
#define ll long long
ll pos(int a){
	ll sum=1;
	for(int i=1;i<=a;i++){
		sum*=10;
	}
	return sum;
}
ll pp(int n){
	ll sum=0;
	for(int i=1;i<=n;i++){
		sum=sum*10+9;
	}
	return sum;
}
int main()
{

	ll n;
	cin>>n;
	ll  temp=n;
	int digit=0;
	while(temp){
		temp/=10;
		digit++;
	}
	if(digit%2==0){
		digit/=2;
		ll num=pos(digit);
		ll t1=n%num;//hou
		ll t2=n/num;//qian
		if(t2>t1) cout<<t2-1;
		else cout<<t2;
		return 0;
	}
	else{
		digit=digit/2;
		ll num=pp(digit);
		cout<<num<<endl;
	}
	return 0;
 }

#include <iostream>
#include <vector>
#include <cstdlib>
#include <algorithm>
#include <string>

using namespace std;

int main() {
    string s;
    cin >> s;
    int nn = s.length();
    int i2 = 9;
    int i4 = 90;
    int i6 = 900;
    int i8 = 9000;
    int i10 = 90000;
    if(nn <= 1){
    	cout<<0;
        return 0;
    }
    else if(nn <= 2){
        long long a = stoll(s.substr(0,1));
        long long b = stoll(s.substr(1,1));
    	if(b >= a) cout<<a;
        else cout<<a-1;

    }
    else if(nn <= 3){cout<<i2;}
    else if (nn<=4){
    	long long a = stoll(s.substr(0,2));
        long long b = stoll(s.substr(2,2));
    	if(b >= a) cout<<a-10+1+i2;
        else cout<<a-10+i2;
    }
    else if(nn <=5){
    	cout<<i2+i4;
    }
    else if(nn <=6){
    	long long a = stoll(s.substr(0,3));
        long long b = stoll(s.substr(3,3));
    	if(b >= a) cout<<a-100+1+i2+i4;
        else cout<<a-100+i2+i4;
    }
    else if(nn <= 7){
     cout<<i2+i4+i6;
    }
    else if(nn <= 8){
    	long long a = stoll(s.substr(0,4));
        long long b = stoll(s.substr(4,4));
    	if(b >= a) cout<<a-1000+1+i2+i4+i6;
        else cout<<a-1000+i2+i4+i6;
    }
    else if(nn <= 9){
    	cout<<i2+i4+i6+i8;
    }
    else if(nn <= 10){
    	long long a = stoll(s.substr(0,5));
        long long b = stoll(s.substr(5,5));
    	if(b >= a) cout<<a-10000+1+i2+i4+i6+i8;
        else cout<<a-10000+i2+i4+i6+i8;

    }
    else if(nn <= 11){
      cout<<i2+i4+i6+i8+i10;

    }
    else if(nn <= 12){
    	long long a = stoll(s.substr(0,6));
        long long b = stoll(s.substr(6,6));
    	if(b >= a) cout<<a-100000+1+i2+i4+i6+i8+i10;
        else cout<<a-100000+i2+i4+i6+i8+i10;

    }
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
using ll = long long;
#define _GLIBCXX_DEBUG
#define rep(i, n) for (ll i = 0; i < (n); ++i)
#define rep1(i, c, n) for (ll i = c; i < (n); ++i)
//以下debug用
#define d(x) cout << #x << "; " << x << endl;
#define p(x) cout << x << endl;
#define f(x) for (long unsigned int i = 0; i < x.size(); i++) cout << #x << "[" << i << "]; " << x[i] << endl;

bool ok = false;

vector<pair<ll,ll>> p;
const int inf = 1001001001;
const ll INF = 1LL << 60; //無限大

ll ans=0,num=0,counter=0;
string s;

int main(){
  int N;
  cin >> N;
  vector<ll> v(N);
  rep(i,N) cin >> v[i];
  set<int> b;
  for (int i = 0; i < N; ++i) b.insert(v[i]);
  if (b.size() == N){
    p("Yes")
  }else{
    p("No")
  }

  return 0;
}

#include <bits/stdc++.h>
using namespace std;
using ll = int64_t; using Vll =vector<ll>; using VVll =vector<vector<ll>>;
template <class T> using Vec = vector<T>; template <class T> using VVec = vector<vector<T>>;
#define INF 9223372036854775807LL/2
void Z(ll i=-1){ if(i==-1)cout<<"Test"<<endl; else cout<<"Test"<<i<<endl; }
template <class T> void VVcout(VVec<T> A){ for(auto Vi:A) { for(auto i:Vi)cout<<i<<' '; cout<<endl;}}
template <class T> void Vcout(Vec<T> A){ for(auto i:A) cout<<i<<' '; cout<<endl;}
template <class T> void chmax(T &x,T y){if(x<y) x=y;} template <class T> void chmin(T &x,T y){if(x==-1 || x>y) x=y;}
#define rep(i,n) for(ll i=0;i<n;i++)
#define reps(si, i,n) for(ll i=si;i<n;i++)

int main(){
    ll n,a;
    cin>>n;
    Vll B(n,0);
    rep(i,n){
        cin>>a;
        B.at(a-1)++;

    }

    bool ans=true;

    rep(i,n) if(B.at(i)!=1) ans=false;

    if(ans) cout<<"Yes"<<endl;
    else cout<<"No"<<endl;

}


/*...........................
.........tank.jpg............
...........................*/

//PointBlank's code (⌐■_■)

#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ull = unsigned long long;
using ld = long double;
template<typename T> using pxx = pair<T, T>;

ll power(ll x, ll y);
#define repp(I, A, B) for(int I = A; I <= B; I++)
#define rep(I, A, B) for(int I = A; I < B; I++)
#define rrep(I, B, A) for(int I = B; I >= A; I--)
#define pb emplace_back
#define ff first
#define ss second
#define all(v) v.begin(),v.end()
#define rall(v) v.rbegin(),v.rend()
#define LB lower_bound
#define UB upper_bound
#define MP make_pair
#define quickio ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0);
#define debug(this) cerr<<"> "<<#this<<" : "<<this<<"\n"
#define bitcount(n) __builtin_popcountll(n)
#define in_edges(M) repp(I, 1, M){int A, B; cin >> A >> B; v[A].pb(B), v[B].pb(A);}
#define in_dedges(M) repp(I, 1, M){int A, B; cin >> A >> B; v[A].pb(B);}
#define in_wedges(M) repp(I, 1, M){int A, B, C; cin >> A >> B >> C; v[A].pb(B, C), v[B].pb(A, C);}
#define in_dwedges(M) repp(I, 1, M){int A, B, C; cin >> A >> B >> C; v[A].pb(B, C);}
#define endl "\n"

const ll sp1 = 1e12 + 39;
const ll sp2 = 1e15 + 1e5 + 11;
const ll INF = 1e18 + 18;
const ll MOD = 1e9 + 7;
const int inf = 2e9 + 9;
const size_t N = 1e6 + 6;

int main() //PointBlank's code ¯\_(ツ)_/¯
{
    quickio
    ull n;
    cin >> n;

    ull a = 3, b = 5;
    ull x = 1, y = 1;
    while(a < INF){
        b = 5, y = 1;
        while(b < INF){
            if(a + b == n){
                cout << x << " " << y;
                exit(0);
            }
            if(b * 5 < b) break;
            b *= 5, y++;
        }
        if(a * 3 < a) break;
        a *= 3, x++;
    }
    cout << -1;
}

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

#include<bits/stdc++.h>
using namespace std;
template<typename T>inline T read(){
	T f=0,x=0;char c=getchar();
	while(!isdigit(c)) f=c=='-',c=getchar();
	while(isdigit(c)) x=x*10+c-48,c=getchar();
	return f?-x:x;
}
#define int long long
namespace run{
	const int N=4e5+9;
	int head[N],nex[N],to[N],cnt;
	inline void add(int u,int v){
		nex[++cnt]=head[u];
		head[u]=cnt,to[cnt]=v;
	}

	int n,m,a[N],b[N],vis[N],tota,totb;
	inline void dfs(int u){
		vis[u]=1,tota+=a[u],totb+=b[u];
		for(int i=head[u];i;i=nex[i])
			if(!vis[to[i]]) dfs(to[i]);
	}
	int main(){
		n=read<int>(),m=read<int>();
		for(int i=1;i<=n;i++) a[i]=read<int>();
		for(int i=1;i<=n;i++) b[i]=read<int>();
		for(int i=1;i<=m;i++){
			int u=read<int>(),v=read<int>();
			add(u,v),add(v,u);
		}

		for(int i=1;i<=n;i++) if(!vis[i]){
			tota=totb=0,dfs(i);
			if(tota!=totb) puts("No"),exit(0);
		}
		puts("Yes");
		return 0;
	}
}
#undef int
int main(){
#ifdef my
	freopen(".in","r",stdin);
	freopen(".out","w",stdout);
#endif
	return run::main();
}


#include <bits/stdc++.h>

using namespace std;
#define IOS ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);
#define endl "\n"
#define int long long

// const int md = 998244353;
const int sz = 1e5+1;

int A[sz+1];
int B[sz+1];
// int C[sz+1];

vector<int> primes;

void sieve(){
    primes.clear();
    for (int i = 0; i <= sz; ++i)
    {
        A[i] = 1;
    }

    for (int i = 2; i <= sz; ++i)
    {
        if(A[i]){
            for (int j = i*i; j <= sz ; j += i)
            {
                A[j] = 0;
            }
        }
    }

    for (int i = 2; i <= sz; ++i)
    {
        if(A[i])
            primes.push_back(i);
    }

}

void solve(){
    int a,b;cin>>b>>a;
    b = 2*(b) + 100;
    cout<<b-a<<endl;
return;
}

int32_t main()
{
    IOS;
    // sieve();
    // int t;cin >> t;
    // while (t--)
        solve();
    return 0;
}

/**In the name of Allah, the Most Merciful, the Most Merciful.**/
#pragma GCC diagnostic ignored "-Wunused-variable"
#pragma GCC diagnostic ignored "-Wunused-parameter"
#pragma GCC diagnostic ignored "-Wunused-but-set-variable"
#pragma GCC diagnostic ignored "-Wformat"
#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;
typedef long long ll;
typedef unsigned long long ull;
#define INF 9223372036854775806
#define pb push_back
#define mp make_pair
#define MOD 1000000007
#define PI 2*acos(0.0)
#define EPS 1e-9
#define base 313
#define base1 431
#define MOD1 999987337
#define maxm 200005
#define maxn 200005

template<class T> using oset=tree<T, null_type, less<T>, rb_tree_tag, tree_order_statistics_node_update>;
//order_of_key,find_by_order
ll max(ll a,ll b) {if(a>b) return a; else return b;} ll min(ll a,ll b) {if(a<b) return a; else return b;}
void FastIO(){
	ios_base :: sync_with_stdio (false);
  	cin.tie(0);
	cout.precision(20);
}

int main()
{
	//what the hell are youing? Think again before coding.
	FastIO();

	int a,b;
	cin>>a>>b;

	ll sum=0;

	for(int i=1;i<=a;i++){
		for(int j=1;j<=b;j++){
			sum=sum+(i*100+j);
		}
	}

	cout<<sum<<endl;

    return 0;
    //you should actually read the stuff at the bottom
}
/* stuff you should look for
	* int overflow, array bounds
	* special cases (n=1?)
	* do smooth instead of nothing and stay organized
	* don't get stuck on one approach, try another
	* don't waste time in one problem, try another
	* check PI value acos(-1.0)
*/