+ 1
How to create an age restricting programme
#include <iostream> using namespace std; int main() { int age; cin>>age; int PARENT'S MOBILE NUMBER; if(age>=18) { cout << "Welcome To Cives Joint" <<endl; } if(age<=14) { cin>>PARENT'S MOBILE NUMBER; } else{ cout << "Please EXIT Cives Joint!" <<endl; } return 0; } How can I make the code to work out in such a way that if the age is 14 or less the user is required to input the parent's phone number?
3 Antworten
+ 5
You can do so but not at SoloLearn. In other editors, you can do so.
0
@Arushi SInghania
Can't the programme further provide an input box for the parent's phone number to further act on the phone number?