0
what is the output of given java for() loop ?
public class Program { public static void main(String[] args) { int[ ] primes = {2, 3, 5, 7}; int i=0; for (int t: primes) { System.out.println(t); System.out.println(primes[i]); i++; } } }
1 Antwort
- 1
2
2
3
3
5
5
7
7