Question: You are to write a program which will request a person's name and birthdate. With this information, the program should print out their exact age
You are to write a program which will request a person's name and birthdate. With this
information, the program should print out their exact age years months, days the
number of days until their next birthday, their astrological sign and personality traits for
that sign.
There is a file zodiac.txt on myCourses, Lecture which gives the relevant dates
and text for each zodiac sign. It is permitted and encouraged that you copy and paste
this code into your program, and make it into a function. Given a signIndex as in
whats your sign, as opposed to positivenegative the function should return the
appropriate string. More on this under Hints, tips, and tricks.
The program should initially ask the person if they would like to get their astrological
personality traits. If the person answers yes, they should then be prompted for their
name and birthdate. After the specified information above is displayed, the user should
again be prompted if they would like to get their astrological personality traits. This
should continue until the user answers no
In the posted solution, there is one additional question, which you may or may not
implement. It asks if you want to use a special date for today which can be useful for
debugging. It is up to you if you want to implement this or not.
Use special date for "today" Y or N: Y
Enter special date for "today":
Would you like to get your Astrological personality traits? yes
Enter name: Jake
Enter birthdate:
Thank you, Jake. Based on the information provided, I can tell you the
following:
You are years, months, and day old
There are days until your next birthday
You were born under the sign of Aries
You have the following personality traits:
Aventurous and energetic
Pioneering and courageous
Enthusiastic and confident
Dynamic and quickwitted
Selfish and quicktempered
Impulsive and impatient
Foolhardy and daredevil
NOTE: Source for AstrologicalZodiac personality traits
is nuclear.ucdavis.edu~rpichapersonalastrology
Would you like to get your Astrological personality traits? y
Enter name: Willomena
Enter birthdate:
Thank you, Willomena. Based on the information provided, I can tell you the
following:
You are years, months, and days old
There are days until your next birthday
You were born under the sign of Cancer
You have the following personality traits:
Emotional and loving
Intuitive and imaginative
Shrewd and cautious
Protective and sympathetic
Changeable and moody
Overemotional and touchy
Clinging and unable to let go
NOTE: Source for AstrologicalZodiac personality traits
is nuclear.ucdavis.edu~rpichapersonalastrology
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
