Your basic structure here should be pretty simple – just use a multiplier and an if statement with a modulus operator.
For example (pseudo-code – check a tutorial if you can’t implement this idea):
int multiplier=1;
int maxMultiplier = 10;
int value = 0;
while (multiplier < maxMultiplier) {
value = 90 * multiplier;
if (multiplier % 2 == 0) {
// print something;
}
multiplier++;
}
1
solved Java for every odd multiply of 90 [closed]