Question: Hw 2 CSC 138 There has been a study made about people's personality and their so believed lucky number. The people who believe that their

Hw 2 CSC 138 There has been a study made about people's personality and their so believed "lucky number". The people who believe that their lucky number is prime are more introverts than the ones who chose non-prime numbers. Input names of people until is introduced, in the place of a name. For each person ask their lucky number. Based on the lucky number, assign true or false to the field introvert. If the number is prime introvert should be set to true otherwise to false. The output should list the names of all the people under one of the two categories: Introvert, or Extrovert. Use the following struct type struct infoPers{

string name

int luckyNum;

bool introvert; };

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!