Lines Matching refs:array
52 public static int constantIndexGet(int array[]) { in constantIndexGet() argument
53 return array[1]; in constantIndexGet()
87 public static void constantIndexSet(int array[]) { in constantIndexSet() argument
88 array[1] = 2; in constantIndexSet()
120 public static int get(int array[], int index) { in get() argument
121 return array[index]; in get()
165 public static void set(int array[], int index, int value) { in set() argument
166 array[index] = value; in set()
233 public static void getSet(int array[], int index) { in getSet() argument
234 array[index] = array[index] + 1; in getSet()
309 public static int[] accrossGC(int array[], int index) { in accrossGC() argument
310 int tmp = array[index] + 1; in accrossGC()
312 array[index] = tmp; in accrossGC()
403 int[] array = {0, 7, 14, 21, 28, 35, 42}; in canMergeAfterBCE1() local
404 for (int i = 0; i < array.length; i++) { in canMergeAfterBCE1()
405 array[i] = array[i] / 7; in canMergeAfterBCE1()
407 return array[array.length - 1]; in canMergeAfterBCE1()
516 int[] array = {128, 64, 32, 8, 4, 2 }; in canMergeAfterBCE2() local
517 for (int i = 0; i < array.length - 1; i++) { in canMergeAfterBCE2()
518 array[i + 1] = array[i] << array[i + 1]; in canMergeAfterBCE2()
520 return array[array.length - 1]; in canMergeAfterBCE2()
647 int[] array = {123, 456, 789}; in main() local
649 assertIntEquals(456, constantIndexGet(array)); in main()
651 constantIndexSet(array); in main()
652 assertIntEquals(2, array[1]); in main()
654 assertIntEquals(789, get(array, 2)); in main()
656 set(array, 1, 456); in main()
657 assertIntEquals(456, array[1]); in main()
659 getSet(array, 0); in main()
660 assertIntEquals(124, array[0]); in main()
662 accrossGC(array, 0); in main()
663 assertIntEquals(125, array[0]); in main()