What do you want to save?
Add Code snippet
New code examples
-
Java 2021-11-21 16:51:20
Reverse an array in java using for loop
// Reverse an array in java using for loop public class ReverseArrayUsingForLoop { public static void main(String[] args) { int[] arrNumbers = new int[]{2, 4, 6, 8, 10}; System.out.println("Given array: "); for(int ... Add solution -
C# 2021-11-20 04:47:10
use a for loop to sum an array c#
int[] arr = new int[] { 1, 2, 3 }; int sum = 0; for (int i = 0; i < arr.Length; i++) { sum += arr[i]; } int[] arr = { 3, 6, 4, 1, 6, 8 }; // returns 1 Array.IndexOf(arr, 6); int maxValue = anArray.Max(); int maxIndex = anArray.ToList().IndexOf(m... Add solution -
Best helpers
Ranking is empty