Answer:
1) B (++ and --)
2) A (1 2 3 4 5)
Explanation:
In the first question, the operators ++ and -- are used in almost all programming languages for adding and subtracting 1 respectively from an operand.
In the second question using a while statement the numbers 1-5 is printed out because the variable n=1 is increased by 1 after each iteration.
Answer & Explanation:
//written in java
public class Main {
private static void printOdd(int[] list) {
for (int value : list) {
if (value % 2 == 1) {
System.out.println(value);
}
}
}
public static void main(String[] args) {
printOdd(new int[]{5, 6, 2, 3, 11, 4, 7});
}
}
Answer:
Wouldn't it be false?
Explanation:
because what if the website doesn't allow some kinds of people on certain pages?
(If its wrong then sorry.)
Answer:
Explanation:
The following code is written in Java and does exactly what the question asks. The variables are long variables instead of integers because integer variables can only be a maximum of 2147483647 and the product of these two variables is much higher than that.
public static void main(String args[]) {
long x = 50000;
long y = x * x;
System.out.println(y);
}
<span>Virtual private network (VPN) is the answer</span>