結果
問題 | No.516 赤と青の風船 |
ユーザー |
![]() |
提出日時 | 2017-05-28 21:22:40 |
言語 | C (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 1 ms / 2,000 ms |
コード長 | 1,483 bytes |
コンパイル時間 | 116 ms |
コンパイル使用メモリ | 30,208 KB |
実行使用メモリ | 5,376 KB |
最終ジャッジ日時 | 2024-09-21 15:15:26 |
合計ジャッジ時間 | 570 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 6 |
ソースコード
#include <stdio.h>#include <stdlib.h>#include <stdbool.h>#include <string.h>#include <math.h>#define REP(i, n) for (ll i = 0; i < n; i++)#define REP1(i, n) for (ll i = 1; i <= n; i++)#define RREP(i, n) for (ll i = n - 1; i >= 0; i--)#define RREP1(i, n) for (ll i = n; i >= 1; i--)#define FOR(i, a, b, c) for (ll i = a; i <= b; i += c)#define RFOR(i, a, b, c) for (ll i = a; i >= b; i -= c)#define MAX(a, b) (a > b ? a : b)#define MIN(a, b) (a < b ? a : b)#define MAX3(a, b, c) MAX(MAX(a, b), c)#define MIN3(a, b, c) MIN(MIN(a, b), c)#define SORT(t, a, n) qsort(a, n, sizeof(t), ({ int _f (const void *_a, const void *_b) { return *(t *)_a - *(t *)_b; } _f; }))#define RSORT(t, a, n) qsort(a, n, sizeof(t), ({ int _f (const void *_a, const void *_b) { return *(t *)_b - *(t *)_a; } _f; }))#define SUM(a, n) ({ ll _s = 0; REP(_i, n) _s += a[_i]; _s; })#define PROD(a, n) ({ ll _p = 1; REP(_i, n) _p *= a[_i]; _p; })#define CNT(x, a, n) ({ ll _c = 0; REP(_i, n) if (a[_i] == x) _c++; _c; })#define MAXM(t, a, n) ({ t _m = a[0]; REP(_i, n) _m = MAX(_m, a[_i]); _m; })#define MINM(t, a, n) ({ t _m = a[0]; REP(_i, n) _m = MIN(_m, a[_i]); _m; })#define INF 1073709056#define LLINF 4611686016279904256LLtypedef long long ll;int main() {char s1[114], s2[514], s3[810];scanf("%s %s %s", s1, s2, s3);int cnt = 0;if (s1[0] == 'R') cnt++;if (s2[0] == 'R') cnt++;if (s3[0] == 'R') cnt++;puts(cnt >= 2 ? "RED" : "BLUE");return 0;}