
Руслан
5 год назад
Написать модуль который будет выводить число из 3 введённых чисел.
ОТВЕТЫ

Pfeiffer Hella
Oct 24, 2020
не совсем точно описал. если рандомом, то:
с++
#include<iostream.h>
int main(int argc, char* argv[])
{ setconsolecp(1251);
setconsoleoutputcp(1251);
float a,b,c;
cout<<"nвведите 3 числа"<<endl;
cout<<'na="; cin>>a>>endl;
cout<<"nb="; cin>>b>>endl;
cout<<"nc"; cin>>c>>endl;
cout << "RAND_MAX = " << RAND_MAX << endl; cout << "random number = " << rand() << endl;
cin>>rand()>>(a,b,c)>>endl;
system (pause);
return 0;
}
с++
#include<iostream.h>
int main(int argc, char* argv[])
{ setconsolecp(1251);
setconsoleoutputcp(1251);
float a,b,c;
cout<<"nвведите 3 числа"<<endl;
cout<<'na="; cin>>a>>endl;
cout<<"nb="; cin>>b>>endl;
cout<<"nc"; cin>>c>>endl;
cout << "RAND_MAX = " << RAND_MAX << endl; cout << "random number = " << rand() << endl;
cin>>rand()>>(a,b,c)>>endl;
system (pause);
return 0;
}
91
Смежные вопросы: