Ampel
#include<iostream.h>
void main() {
int note; cout<<"Note:"; cin>>note; if (note<4) { cout<<"GRUEN!!!!!!!!!"; } else { if (note==4) { cout<<"GELB!!!!!!!!"; } else { cout<<"ROT!!!!!!"; } } cout<<endl;
int note; cout<<"Note:"; cin>>note; if (note<4) {
cout<<"GRUEN!!!!!!!!!";
} else {
if (note==4) { cout<<"GELB!!!!!!!!"; } else { cout<<"ROT!!!!!!"; }
if (note==4) {
cout<<"GELB!!!!!!!!";
cout<<"ROT!!!!!!";
}
} cout<<endl;
<<zurück>>