A binary file is a collection of bytes. What these bytes represent depend upon the definition of the file format. For a BMP file, the first group of bytes (what we call the header) represent information about the image. How many bytes and what they mean are defined as described in the wiki link above.
Here's an analogy. Let's say you have a series of letters: G, Y, R, G, Y, R, G, Y, R.
Without any context, these letters have no discernable meaning.
But if I were to say, "these letters represent the states of a traffic light", then those letters now have meaning (the light starts on Green, goes to Yellow, then to Red, then back to Green, and so on), since a context was defined.
It's the same with a binary file. What the bytes represent depend upon the context in which they're read.
"%x" is used for printing hex. This probably isn't necessary, but I personally find it easier to read hex values when working with binary.
Code:
#include <stdio.h>
#define BYTES 8
int main(void)
{
unsigned char byte[BYTES] = { 0x10, 0x0A, 0xFF, 0x00, 0x35, 0xC8, 0xEF, 0x77 };
int i;
printf("Hex Dec\n\n");
for(i = 0; i < BYTES; i++)
printf("%02X = %3d\n", byte[i], byte[i]);
return 0;
}