This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
If the byte array has the decimal representation of of a number...
If the byte array has been read from some file, you could get clever and use a ByteArrayInputStream to read bytes out of the bye array and wrap that in (decorate it with) a DataInputStream to convert the bytes to a long. Tom make the code as dense as possible, you could do it all one line:
You'll have to try/catch the IOException that the readLong() might throw. What you do in that case is up to you.