forked from cosmonaut/wraith-lang
20 lines
266 B
OpenEdge ABL
20 lines
266 B
OpenEdge ABL
|
struct Program
|
||
|
{
|
||
|
static Main(): int
|
||
|
{
|
||
|
sum: int;
|
||
|
|
||
|
sum = 0;
|
||
|
|
||
|
for (i in [1..1000])
|
||
|
{
|
||
|
if ((i % 3 == 0) || (i % 5 == 0))
|
||
|
{
|
||
|
sum = sum + i;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
return sum;
|
||
|
}
|
||
|
}
|