# Codeforces Round #387 (Div. 2) Archive

## Codeforces Round #387 (Div. 2), problem: (F) Igor and Interesting Numbers Solution in C/C++

Codeforces Round #387 (Div. 2), problem: (F) Igor and Interesting Numbers Solution in C/C++   #include <bits/stdc++.h> #define ll long long using namespace std; const int N=1<<16; int k,t,len; ll c; void print(int x) { …

## Codeforces Round #387 (Div. 2), problem: (E) Comments Solution in C/C++

Codeforces Round #387 (Div. 2), problem: (E) Comments Solution in C/C++   #include <stdio.h> #include <string.h> #include <stdlib.h> #define N 1000000 int ccnt; struct comment { char *s; int d, i; } cc; char *ss; …

## Codeforces Round #387 (Div. 2), problem: (D) Winter Is Coming Solution in C/C++

Codeforces Round #387 (Div. 2), problem: (D) Winter Is Coming Solution in C/C++     #include <limits.h> #include <stdio.h> #include <stdlib.h> int compare(const void *a, const void *b) { int *pa = (int *) a; …

## Codeforces Round #387 (Div. 2), problem: (C) Servers Solution in C/C++

Codeforces Round #387 (Div. 2), problem: (C) Servers Solution in C/C++   #include<stdio.h> int main(){ int n,q,a={0},t,k,d,i,j,s,f; scanf("%d%d",&n,&q); while(q>0) { scanf("%d%d%d",&t,&k,&d); s=0; for(i=0;i<n;i++) { if(a<t) a=0; } j=0; for(i=0;i<n;i++) { if(a==0) j++; } if(j<k) printf("-1\n"); …

## Codeforces Round #387 (Div. 2), problem: (B) Mammoth’s Genome Decoding Solution in C/C++

Codeforces Round #387 (Div. 2), problem: (B) Mammoth’s Genome Decoding Solution in C/C++   #include <stdio.h> char cc = { 'A', 'C', 'G', 'T' }; int cnt; void incr(char c) { int i; for (i …

## Codeforces Round #387 (Div. 2), problem: (A) Display Size Solution in C/C++

Codeforces Round #387 (Div. 2), problem: (A) Display Size Solution in C/C++   int main(){ long long int x,i; scanf("%I64d",&x); i=sqrt(x); while(x%i){ i--; } printf("%I64d %I64d",i,x/i); }