For Apple store services and apps(like games, videos, etc ): you can gain access if you are15years old or less and your parent has an Apple ID. If you are 16 years old or more you need to have your own Apple ID.
Write a program that uses short circuit logic to tell someone if they are legal to gain access to Apple store services. First ask them how old they are, whether they have an Apple ID or not, and whether their parent has an Apple ID or not.
age=int(input("Enter your age: "))
if (age<=15):
ID=input("Do you have your parents Apple ID? ")
if ID=='yes':
parentId=int(input("Enter your parents Apple ID: "))
print("you are allowed to access Apple store services using id ",parentId)
elif ID=='no':
print("You cannot access Apple store")
else:
print("Please type yes or no")
else:
yourId=int(input("Enter your id:"))
print("you are allowed to access Apple store services using id ",yourId)
Comments
Leave a comment