Ticket office discount program of c++ | Sololearn: Learn to code for FREE!
¡Nuevo curso! ¡Todo programador debería aprender IA Generativa!
Prueba una lección gratuita
0

Ticket office discount program of c++

A array of persons . We give discount at the minimum age of the people.

28th Mar 2023, 4:04 PM
Sagar
2 Respuestas
+ 1
#include <iostream> using namespace std; int main() { int ages[5]; int min=ages[0]; for (int i = 0; i < 5; ++i) { cin >> ages[i]; for(int j=0;j<5;j++) { if(ages[j]<min) { min=ages[j]; } } } //your code goes here double rslt; rslt /=100; rslt *=50; rslt =50-rslt; cout<<rslt; return 0; }
29th Mar 2023, 3:34 AM
Sagar
+ 1
Can I see your attempts?
28th Mar 2023, 5:06 PM
Knight
Knight - avatar