#include<bits/stdc++.h> using namespace std; const int maxn=16,INF=0x3f3f3f3f; char type[maxn]; int R[maxn],B[maxn]; char readchar() { for(;;) { char ch=getchar(); if(!isspace(ch)) {..

#include <limits.h> #include <stdio.h> #define N 1000 void query(int *ww, int *aa, int k, int n) { int i; printf("%d\n",..

#include <stdio.h> #include <string.h> int c[1005], p[1005], sz[1005], gov[1005]; int find_parent(int n) { if (p[n] == n) return n; return..

#include <limits.h> #include <stdio.h> int main() { int i, j, n, m, cnt, imin, jmin, imax, jmax; static char cc[500][501];..

#include<stdio.h> #include<string.h> void cycle(char s[],int len) { char temp=s[len-1]; int i; for(i=len-1;i>0;i--) { s[i]=s[i-1]; } s[0]=temp; } int main(){ char..

#include <stdio.h> #include <string.h> #define MIN(X,Y) ((X)<(Y) ? (X) : (Y)) int n,c[1010],r[1010][10][1010],dp[10][300][1010]; int solve(int aver,int c,int b,int k); int..

#include <stdio.h> #include <string.h> #define MAX(X,Y) ((X)>(Y) ? (X) : (Y)) #define INF 1000000000000000 typedef long long LL; int n,sz,first[200010],next[400010],tail[400010],son[200010],bro[200010],vis[200010];..

#include<stdio.h> int main(){ long x; scanf("%ld",&x); if(x==1) printf("-1"); else printf("%ld %ld %ld",x,x+1,x*(x+1)); return 0; }

long long k; main() { scanf("%d%lld",&k,&k); printf("%d\n",1+__builtin_ctzll(k)); }

#include<stdio.h> int main() { int i,j,n,a,b; char s[100003]; scanf("%d%d%d",&n,&a,&b); scanf("%s",s); if(s[a-1]==s[b-1]) { printf("0"); } else printf("1"); return 0; }