Top "Byte" questions

A unit of information usually corresponding to 8 bits.

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 …

java arrays int byte endianness
C++ How to combine two signed 8 Bit numbers to a 16 Bit short? Unexplainable results

I need to combine two signed 8 Bit _int8 values to a signed short (16 Bit) value. It is important that the …

c++ byte signed short
Add "b" prefix to python variable?

Adding the prefix "b" to a string converts it to bytes: b'example' But I can't figure out how to do …

python python-3.x byte
Converting struct to byte and back to struct

I'm currently working with Arduino Unos, 9DOFs, and XBees, and I was trying to create a struct that could be …

c++ struct byte arduino xbee
Java Iterate Bits in Byte Array

How can i iterate bits in a byte array?

java arrays byte bit loops
byte array to short array and back again in java

I'm having some issues taking audio data stored in a byte array, converting it to a big-endian short array, encoding …

java arrays byte type-conversion short
Getting the size of a field in bytes with C#

I have a class, and I want to inspect its fields and report eventually how many bytes each field takes. …

c# reflection byte
C# Append byte array to existing file

I would like to append a byte array to an already existing file (C:\test.exe). Assume the following byte …

c# arrays byte append concatenation
Byte to Binary String C# - Display all 8 digits

I want to display one byte in textbox. Now I'm using: Convert.ToString(MyVeryOwnByte, 2); But when byte is has 0's …

c# .net string byte bits
How many bytes will a string take up?

Can anyone tell me how many bytes the below string will take up? string abc = "a";

c# string byte