How to convert a Byte Array to an Int Array
问题 I am reading a file by using: int len = (int)(new File(args[0]).length()); FileInputStream fis = new FileInputStream(args[0]); byte buf[] = new byte[len]; fis.read(buf); As I found here. Is it possible to convert byte array buf to an Int Array ? Is converting the Byte Array to Int Array will take significantly more space ? Edit: my file contains millions of ints like, 100000000 200000000 ..... (written using normal int file wirte). I read it to byte buffer. Now I want to wrap it into