This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int main() { | |
double r; | |
int n; | |
while (cin >> r >> n, r) { | |
vector<double> h(60, 0.0); | |
auto height = h.begin() + 30; | |
REP(i,n) { | |
int xl, xr; | |
double y; | |
cin >> xl >> xr >> y; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int main() { | |
int n, m; | |
while (cin >> n >> m, n) { | |
vector<C> circle(n); | |
vector<P> point(m); | |
ld x, y, r; | |
REP(i,n) { | |
cin >> x >> y >> r; | |
circle[i] = (C){P(x, y), r}; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int f(int a, int b) { | |
return a * (100+b) / 100; | |
} | |
int main() { | |
int x, y, s; | |
while (cin >> x >> y >> s, x) { | |
int res = -1; | |
REP(i,1024) REP(j,1024) { | |
if (i == 0 || j == 0) continue; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
string f(string s) { | |
for (char c = 'b'; c <= 'z'; c++) { | |
REP(i,s.size()) { | |
if (s[i] == c) { | |
s[i]--; | |
break; | |
} | |
} | |
} | |
return s; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <vector> | |
#include <string> | |
#include <cstring> | |
#include <map> | |
#include <queue> | |
#include <algorithm> | |
#define REP(i,n) for(int i=0;i<(int)(n);i++) | |
#define ALL(x) (x).begin(),(x).end() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <vector> | |
#include <string> | |
#include <cstring> | |
#include <map> | |
#include <queue> | |
#include <algorithm> | |
#define REP(i,n) for(int i=0;i<(int)(n);i++) | |
#define ALL(x) (x).begin(),(x).end() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <vector> | |
#include <string> | |
#include <cstring> | |
#include <set> | |
#include <map> | |
#include <queue> | |
#include <algorithm> | |
#define REP(i,n) for(int i=0;i<(int)(n);i++) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <vector> | |
#include <string> | |
#include <cstring> | |
#include <map> | |
#include <queue> | |
#include <algorithm> | |
#define REP(i,n) for(int i=0;i<(int)(n);i++) | |
#define ALL(x) (x).begin(),(x).end() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <vector> | |
#include <string> | |
#include <cstring> | |
#include <map> | |
#include <cmath> | |
#include <queue> | |
#include <algorithm> | |
#include <iomanip> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <vector> | |
#include <string> | |
#include <cstring> | |
#include <map> | |
#include <queue> | |
#include <algorithm> | |
#include <iomanip> | |
#define REP(i,n) for(int i=0;i<(int)(n);i++) |