Submission
Status:
PPPPPPPPPP
Subtask/Task Score:
100/100
Score: 100
User: sakuragichan
Problemset: ผลรวมตัวเลข
Language: cpp
Time: 0.002 second
Submitted On: 2026-09-08 07:24:42
#include <bits/stdc++.h>
using namespace std;
int main() {
int x, y , z = 0;
cin >> x >> y;
for (int i = x; i< y ;++i) {
if (i % 2 == 0 || i % 3 == 0) {
z += i;
}
}
cout << z;
return 0;
}