Here you can find the source of intArrayContains(int[] array, int key)
public static boolean intArrayContains(int[] array, int key)
//package com.java2s; //License from project: Apache License public class Main { public static boolean intArrayContains(int[] array, int key) { for (final int i : array) { if (i == key) { return true; }/* w w w . j a v a2 s.c o m*/ } return false; } }