/*
* https://p...content-available-to-author-only...r.net/problem=1
*/
#include <stdio.h>
#define SIZE (10)
int main(void) {
int list[SIZE] = { 0 };
int sum = 0;
int i;
for (i = 3; i < SIZE; i += 3) ++list[i];
for (i = 5; i < SIZE; i += 5) ++list[i];
for (i = 3; i < SIZE; i += 2) if (list[i]) sum += i;
return 0;
}
LyoKICogaHR0cHM6Ly9wLi4uY29udGVudC1hdmFpbGFibGUtdG8tYXV0aG9yLW9ubHkuLi5yLm5ldC9wcm9ibGVtPTEKICovCiNpbmNsdWRlIDxzdGRpby5oPgojZGVmaW5lIFNJWkUgKDEwKQppbnQgbWFpbih2b2lkKSB7CglpbnQgbGlzdFtTSVpFXSA9IHsgMCB9OwoJaW50IHN1bSA9IDA7CglpbnQgaTsKCQoJZm9yIChpID0gMzsgaSA8IFNJWkU7IGkgKz0gMykgKytsaXN0W2ldOwoJZm9yIChpID0gNTsgaSA8IFNJWkU7IGkgKz0gNSkgKytsaXN0W2ldOwoJZm9yIChpID0gMzsgaSA8IFNJWkU7IGkgKz0gMikgaWYgKGxpc3RbaV0pIHN1bSArPSBpOwoJcHJpbnRmKCIlZFxuIiwgc3VtKTsKCQoJcmV0dXJuIDA7Cn0K