Platinum Partner
java

Convert an Int to a Byte Array

Convert an int into a byte array with this short code snippet.


    public static byte[] intToByteArray(int value) {
        byte[] b = new byte[4];
        for (int i = 0; i >> offset) & 0xFF);
        }
        return b;
    }


{{ tag }}, {{tag}},

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}
{{ parent.authors[0].realName || parent.author}}

{{ parent.authors[0].tagline || parent.tagline }}

{{ parent.views }} ViewsClicks
Tweet

{{parent.nComments}}