惠普c5-1710_惠普c5-1710代码

  • 惠普c5-1710_惠普c5-1710代码已关闭评论
  • A+
摘要

#includeusingnamespacestd;intmain(){//Declarevariablesdoubleprice,discount;//Getthepricecout<>price;//Cal

远程打印机维修中心

#include
using namespace std;

int main() {
// Declare variables
double price, discount;

// Get the price
cout << "Please enter the price: "; cin >> price;

// Calculate the discount
if (price > 1000) {
discount = price * 0.1;
} else {
discount = price * 0.05;
}

// Calculate the total price
double totalPrice = price - discount;

// Print the results
cout << "The discount amount is: $" << discount << endl; cout << "The total price is: $" << totalPrice << endl; return 0; }

  • 在线QQ客服
  • 扫码远程服务QQ:51154898
  • weinxin
  • 在线微信清零客服
  • 正版软件 扫我远程清零
  • weinxin