support@unifiedpapers.com

astronomy-project-1

ANSWER HAVE TO BE AS PER REQUIREMENTS.

NO COPIED PLEASE.

Project Description

In the real world, you are most likely going to edit existing code than to start everything anew in your job. In this project, you are going to edit the given astrology program.

Recently there are talks about a new zodiac sign Ophiuchus (of water element). Your boss would like you to edit your company’s astrology program to accommodate the addition.

And while you are at it, she wants you to also make sure to allow users to re-input the birth dates if they made a mistake.

Original Astrology Program

Currently the user is asked to type in data for two people: name, birth month and day. And the program responds with the signs, and if the birthday is only one or two days away from an adjacent sign, the program announces that the birthday is on a “cusp”. And then the program will tell the user whether these two people are compatible based on their sign elements.

The 12 horoscope signs and dates are the following, which the original astrology program is based on:
Aries March 21–April 19 (day 81 – 110)
Taurus April 20–May 20 (day 111 – 141)
Gemini May 21–June 21 (day 142 – 173)
Cancer June 22–July 22 (day 174 – 204)
Leo July 23–August 22 (day 205 – 235)
Virgo August 23–September 22 (day 236 – 266)
Libra September 23–October 22 (day 267 – 296)
Scorpio October 23–November 21 (day 297 – 326)
Sagittarius November 22–December 21 (day 327 – 356)
Capricorn December 22–January 19 (day 357 – 19)
Aquarius January 20–February 18 (day 20 – 49)
Pisces February 19–March 20 (day 50 – 80)

A Cusp and a Sign is Only 2 Days Away

Let’s look at an example based on the original program:

Pisces February 19–March 20 (day 50 – 80)

Aries March 21–April 19 (day 81 – 110)

Ken & Amy

Enter your name: Ken
Enter your birthday (month day): 3 23
Enter your friend's name: Amy
Enter his/her birthday (month day): 3 22
Ken is a ARIES. 
Amy is a ARIES. He/she is also a cusp of PISCES. 
Ken is compatible with Amy.

Mark & Jane:

Enter your name: Mark
Enter your birthday (month day): 3 18
Enter your friend's name: Jane
Enter his/her birthday (month day): 3 19
Mark is a PISCES. 
Jane is a PISCES. He/she is also a cusp of ARIES. 
Mark is compatible with Jane.

What is the Element of a Sign

Horoscope Signs of the same Element are most compatible. There are 4
Elements in astrology, and 3 Signs in each: FIRE (Aries, Leo, Sagittarius),
EARTH (Taurus, Virgo, Capricorn), AIR (Gemini, Libra, Aquarius) , WATER (Cancer, Scorpio, Pisces).

Given Program Files

These are the program files for the original program:

main.cpp

horoscope.h

horoscope.cpp

Your Boss’s Requirements

  1. Edit the program to work for the 13-sign system, and assume the new Ophiuchus sign is of Water element. Here are the new dates:
    1. Capricorn January 21 – February 16 (day 21 – 47)
    2. Aquarius February 17 – March 11 (day 48 – 71)
    3. Pisces March 12 – April 18 (day 72- 109)
    4. Aires April 19 – May 13 (day 110 – 134)
    5. Taurus May 14 – June 21 (day 135 – 173)
    6. Gemini June 22 – July 20 (day 174 – 202)
    7. Cancer July 21 – August 10 (day 203 – 223)
    8. Leo August 11 – September 16 (224 – 260)
    9. Virgo September 17 – October 30 (day 261 – 304)
    10. Libra October 30 – November 23 (day 305 – 328)
    11. Scorpio November 24 – November 29 (day 329 – 334)
    12. Ophiuchus November 30 – December 17 (day 335 – 352)
    13. Sagittarius December 18 – January 20 (day 353 – 20)
  2. Implement error checking for birth month/day input. Allow users to reenter if they made a mistake.
  3. Impeccable programming style and comments.
  4. Answer all questions in the Problems Encountered section.

What to Submit

Submit for this lab all your program files in .h and .cpp.

Tips

  1. Run the original program to make sure it works first.
  2. Test all the boundary cases (where the signs change and at cusp) as well as regular cases.
  3. Test when user enter invalid dates, such as “20” or “abc” for month.

Demo of Program

Enter your name: Ken

Enter your birthday (month day): 11 23

Enter your friend’s name: Amy

Enter his/her birthday (month day): 11 28

Ken is a SCORPIO. He/she is also a cusp of LIBRA.

Amy is a SCORPIO. He/she is also a cusp of OPHIUCHUS.

Ken is compatible with Amy.

Problems Encountered

In the end of your main.cpp file, add a blocked comment section as follows and fill it out:

/* ==========================================================

Q1. Problems I had working on this assignment (and how I overcame these problems)
1.
2.
Q2. Did you find any problems in the original program?
========================================================== */

"Get 15% discount on your first 3 orders with us"
Use the following coupon
FIRST15

Order Now

Hi there! Click one of our representatives below and we will get back to you as soon as possible.

Chat with us on WhatsApp