Makes a lot of sense to me.
Open file for reading. Loop until end of file.
Read 4 bytes, store in temp. Check the first char (index 0), if it's m or f. Set to appropriate pointers to the correct variables.
Read 4 new bytes. Convert to double and add to the specific gpa using the pointer. Increase the amount of male or female occourances.
Then divide female and male GPA by the number of occourances in the file.
Format a string into ToDisplay and print it.
What doesn't make sense? It should make sense. Unless you don't know about pointers? Or maybe you don't understand fopen/fread/feof? I tend to never use istream, so unfortunately it's the only way I know of. But feel free to modify the code. Use the docs to find what the functions does and change it to a similar code with your code.