Sounds like you need to learn some basics for your job. At first you need to read the file. How it can be done is explained in Input/output with files
After that you must split the string in parts as discussed in this answer of stackoverflow
. I like the last sample code most.
Than use the stroul function to parse the hex-string into a number and you are on the final output step, which should be a piece of cake.