HTML
1
Вклад в тег
div#div1:empty + div#div2 {display: none;}
<div id="div1"></div>
<div id="div2"></div>
public class LoopWithStep {
int res = getSum(5, 10);
public static int getSum(int n, int step) {
int result = 0;
for (int i = 0; i <= n; i = i + step) {
result += i;
}
return result;
}
}