Q:

Correct Way to Add byte Variables into byte Arrays

What I am trying to do is get input from the user and store it in a byte array. Please note, I must store var1 variable in a byte array and not a list.
Console.Write("Enter a number: ");
byte var1 = byte.Parse(Console.ReadLine());
byte[] byteArray = new byte[] {};
byteArray[0] = var1;

A:

Arrays are fixed in size, you must specifiy the size of the array when you create it. In your example you told it to make an array of size 0 by putting the {} after the byte[]. Instead remove the {} and just put a 1 between the []
Console.Write("Enter a number: ");
byte var1 = byte.Parse(Console.ReadLine());
byte[] byteArray = new byte[1];
byteArray[0] = var1;

