C++ double type mixed expressions

Description

C++ double type mixed expressions

#include <iostream>
using namespace std;
int main()/*ww w.  j  av  a 2s  .c o m*/
{
   int count = 7;
   float avgWeight = 155.5F;
   double totalWeight = count * avgWeight;
   cout << "totalWeight=" << totalWeight << endl;
   return 0;
}



PreviousNext

Related