标题: C语言实现两个小数相乘 [打印本页] 作者: 菜鸟adambo 时间: 2015-10-24 18:43 标题: C语言实现两个小数相乘 /*C program to multiply and display the product of two floating point numbers entered by user. */
#include <stdio.h>
int main( )
{
float num1, num2, product;
printf("Enter two numbers: ");
scanf("%f %f",&num1,&num2); /* Stores the two floating point numbers entered by user in variable num1 and num2 respectively */
product = num1*num2; /* Performs multiplication and stores it */
printf("Product: %f",product);
return 0;
}作者: 小Who 时间: 2015-10-25 15:21
纯英文注释,好厉害作者: 张水 时间: 2015-10-25 16:47
好腻害!!!!!!!!!!作者: stanfor 时间: 2015-10-26 09:26
入乡呢,还是随俗的好...