This assignment is designed to predict a persons choice in t

This assignment is designed to predict a person’s choice in the current presidential election. Research and identify the pros or cons of each presidential candidate(Trump, Clinton) as it relates to the following issues:

·         Education

·         Crime

·         Foreign Policy

·         Gun Laws

·         Health

·         Immigration

·         National Security

·         Sex and Gender

·         Science and the Environment

·         Race

Develop two unbiased questions relating to each issue. There will be a total of 20 questions. Depending upon how the user answers a question, a tally will be given to the candidate who is pro on the issue.

For Example: For the topic of Immigration:

1. Should the United States build a wall or fence around the Mexican Border?(y/n)

2. Should the United States allow Syrian refugees into the country? (y/n)

If the answer is yes, Trump’s votes will increase by 1. If the answer is no, Clinton’s point should increase by 1. Check for invalid entry (neither yes or no). Ask again if invalid.

When all questions have been asked and input received, tally the number of votes for each candidate to determine the user’s presidential choice. Display the results and identify the winner.Sample program Below of the program written for the 2004 Election:

Solution

#include <stdio.h>

int main()
{
int t_votes;
int c_votes;
char choice;
printf(\"Is present U.S education system is good or not: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"Are U.S Education system treating students of other countries properly or not : y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\" Should we move away from treating the use of drugs as a crime : y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"Should the United States Abide by Its Treaties with Native American Tribes?: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"should U.S support pakistan\'s terrorism : y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"U.S has good relationships with all countries: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"Many analysts characterize Canada’s gun laws as strict in comparison to those of the United States do think it is correct: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"A well-regulated Militia, being necessary to the security of a free State is this correct: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"How would be weather in us good or not: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"How would be us government hospitals?: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"Compared to American citizens, how likely do you think ILLEGAL immigrants are to commit crimes?: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"Overall, do you think immigrants from other countries mainly strengthen or mainly weaken American society?: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"Should Law Enforcement Be Allowed to Use Racial Profiling?: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"Is Harvard Educational Review arguing that the most important test in America, the SAT, was racially biased: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"Instead of considered discussion of first-order security concerns, the candidates have regularly opted for bluff and bluster.: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"national security, election 2016 promises to be not just a missed opportunity but a complete bust.: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"Stanford sociologist urges rethinking of sex and gender in surveys: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"everywhere in the world women are good in child rearing,: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"Is the government provideng funds to the scientists correctly: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
printf(\"how Values of Science and Impact on Policy: y/n\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
else{
printf(\"\ Invalid entery.Please enter correctly\ \");
scanf(\"%c\",&choice);
if(choice==\'y\')
t_votes++;
else if(choice==\'n\')
c_votes++;
}
if(t_votes>c_votes){
printf(\"The winner is Trump with number of votes %d\",t_votes);
printf(\"clinton votes are:%d\",c_votes);
}
else if(c_votes>t_votes){
printf(\"The winner is clinton withc nunmber of votes %d\",c_votes);
printf(\"Trump votes are :%d\",t_votes);
  
}
else
printf(\"both got same votes:%d\"t_votes);
return 0;
}

This assignment is designed to predict a person’s choice in the current presidential election. Research and identify the pros or cons of each presidential candi
This assignment is designed to predict a person’s choice in the current presidential election. Research and identify the pros or cons of each presidential candi
This assignment is designed to predict a person’s choice in the current presidential election. Research and identify the pros or cons of each presidential candi
This assignment is designed to predict a person’s choice in the current presidential election. Research and identify the pros or cons of each presidential candi
This assignment is designed to predict a person’s choice in the current presidential election. Research and identify the pros or cons of each presidential candi
This assignment is designed to predict a person’s choice in the current presidential election. Research and identify the pros or cons of each presidential candi

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site