Type casting is not the problem here. Even if the type cast is wroung the program will still compile, you'll just get undesired results thats all. Kinda like this
Code:
Printf("4 + 4 = %d");
//this could return anything like "4 + 4 = 4098
//now how did that happen?