Submission #1587469


Source Code Expand

#include <bits/stdc++.h>
using namespace std;
#define FOR(i, n) for(int i = 0; i < (n); i++)
#define MEM(a, x) memset(a, x, sizeof(a))
#define ALL(a) a.begin(), a.end()
#define UNIQUE(a) a.erase(unique(ALL(a)), a.end())
typedef long long ll;

int n;

int main(int argc, char const *argv[]) {
	ios_base::sync_with_stdio(false);
	cin >> n;
	int ret = 0;
	FOR(i, n) {
		int a;
		cin >> a;
		if (a % 3 == 2) {
			a--;
			ret++;
		}
		if (a % 2 == 0) ret++:
	}
	cout << ret << endl;
	return 0;
}

Submission Info

Submission Time
Task B - 花占い
User moguta
Language C++14 (GCC 5.4.1)
Score 0
Code Size 515 Byte
Status CE

Compile Error

./Main.cpp: In function ‘int main(int, const char**)’:
./Main.cpp:22:24: error: expected ‘;’ before ‘:’ token
   if (a % 2 == 0) ret++:
                        ^