Mega Code Archive

 
Categories / Java Tutorial / Collections
 

Compare two byte type arrays

import java.util.Arrays; public class Main {   public static void main(String[] argv) throws Exception {     boolean b = Arrays.equals(new byte[] { 0 }, new byte[] { 0 }); // true   } }