Q. The correct syntax for running two variable for loop simultaneously is

  • (A) for (i = 0; i < n; i++) for (j = 0; j < n; j += 5)
  • (B) for (i = 0, j = 0;i < n, j < n; i++, j += 5)
  • (C) for (i = 0; i < n;i++){}
  • (D) for (j = 0; j < n;j += 5){}
πŸ’¬ Discuss
βœ… Correct Answer: (B) for (i = 0, j = 0;i < n, j < n; i++, j += 5)

You must be Logged in to update hint/solution

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
268
Total Visits
πŸ“½οΈ
4 y ago
Published
πŸŽ–οΈ
Indresh Gehalot
Publisher
πŸ“ˆ
86%
Success Rate