Visual C++ 2005 Express Edition 使ってCの勉強最近始めたっばかりなんだが

#include <stdio.h>
int main()
{
int a = 10;
int b = 7;
double c = (double) (a+b)/2.0;
printf("%f",c);
return 0;
}

「10」と「7」の平均を求め、小数点以下まで正しく表示させる問題で
上のが答えで下のが自分でやったものでどっちとも同じ答えが出力されるのですが
これはこれでいいのでしょうか?

#include <stdio.h>
int main()
{
short a = 10;
short b = 7;
float c = (a+b)/2.0;
printf("%f",c);
return 0;
}