Let's say I have array of bytes 

```
byte[] arr = new byte[16];

```

and I filled only 10 of those 16 bytes

```
arr[0] = 1;
arr[1] = 1;
arr[2] = 2;
arr[3] = 3;
arr[4] = 4;
arr[5] = 5;
arr[6] = 6;
arr[7] = 7;
arr[8] = 8;
arr[9] = 9;
arr[10] = 1;

```

the problem is that user can input up to 10 digits, and the last digit could be 0

How can I find how many digits my array holds, since arr.Length and arr.Count() will give 16 but I need to know that it's 10?