Computer Science, asked by asmitadey6615, 5 months ago

Write a program to get input name and age from user. Your program should determine either the user is adult or child (adult >=18 years, child <18). If user is adult, ask him to enter his/her employer’s name, otherwise ask user enter his/her school’s name
how to solve this???

Answers

Answered by allysia
0

Answer:

A python program goes like:

\\\tt a=int(inp ut("E nter\ your\ age: ")) \\\tt if\ a&gt;=18: \\\tt { \qquad   i=inp ut("En ter\ your\ emplo yer's\ na me: ")}\\\tt  {\qquad    pri nt("User\ is\ adult.")} \\\tt    else: \\\tt { \qquad   i=inp ut("En ter\ your\ school's\ na me: ")} \\\tt {\qquad    pri nt("User\ is\ not\ an\ adult.")}

Similar questions