orlandoju

Ejer8

Mar 30th, 2022
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1.  
  2. #include <iostream>
  3. using namespace std;
  4.  
  5. int main(void){
  6. float venta,venta_con_desc,valor_porc;
  7.  
  8. cout<< "Ingrese el importe de venta sin descuento: $ " ;
  9. cin>> venta;
  10. cout<< "Ingrese el importe de venta con descuento : $ " ;
  11. cin>> venta_con_desc;
  12. valor_porc=venta - venta_con_desc;
  13. cout<< "El porcentaje aplicado en esta venta es de: "<< valor_porc*100/venta<< "%" <<endl;
  14.  
  15. return 0;
  16. }
  17.  
Advertisement
Add Comment
Please, Sign In to add comment