برنامه ی ضرب دو عدد به زبان سی پلاس پلاس
جمعه, ۱۶ مهر ۱۳۹۵، ۰۷:۱۵ ب.ظ
gameover.blog.ir
/*C++ program to multiply and display the product of two numbers entered by user. */
#include <iostream>
using namespace std;
int main( )
{
float n1, n2, product;
cout << "Enter two numbers: ";
cin >> n1 >> n2;
product = n1*n2;
cout << "Product = " << product;
return 0;
}
Output
Enter two numbers: 2.4 1.6 Product = 3.84
Enter two numbers: 11 13 Product = 143
۹۵/۰۷/۱۶