1.Module 5 - Practice Question
Mr. Jay Brown is 66 years of age and his 2020 income is made up of
...
loyment
income of $75,800, contributed $6,500 to his RRSP. He also earned interest
income from Guaranteed Investment Certificate (GIC) of $3,700 during 2020 and
received Old Age Security benefits of $7,400 (because of large business losses
during the previous two years, no amount was withheld from the OAS payments).
Mr. Brown and his family live in Toronto, Ontario. For 2020, Mr. Brown’s
employer withheld maximum CPP ($2,898) and EI ($856) contributions. Other
information pertaining to 2020 is as follows:
1. Mr. Brown’s spouse is 59 years old and qualifies for the disability tax credit.
Her income for the year totaled $4,500.
2. Mr. and Mrs. Brown have two daughters, Keith, aged 15 and Laura, aged
17. Keith had income of $2,700 for the year while Laura had net income of
$3,000. In September 2020, Laura began full time attendance at a Canadian
university. Mr. Brown paid her tuition fees of $6,000, of which $3,500 was
for the fall 2020 semester. Laura is willing to transfer her tuition credit to
her father.
3. The family medical expenses for the year, all of which were paid by Mr.
Brown, totaled $3,845. Of this amount, $300 was paid for Keith and $900
for Laura.
4. During the year, Mr. Brown made cash donations to registered Canadian
charities in the amount of $2,000.
5. During the year, Mr. Brown made contributions to federal political parties
totaling $1,800.
Required: Use the above information to determine Mr. Brown’s
- Clawback amount for the social benefit repayment
- Net income for tax purposes
- Federal tax payable before tax credit (Gross tax)
- Tax credits available
- Federal tax payable for 2020.
View More
2.CSE 1300
Problem Solving Practice Conditional Statements
Question 1: Student Fees
All KSU students pay fees in addition to their tuition.
Using the code
...
nts pay fees in addition to their tuition.
Using the code provided below as a starting point, write a conditional statement that determines how much a student will pay in fees.
• Students registered for 1 – 4 hours pay $843 in student fees.
• Students enrolled in 5 or more hours pay $993 in student fees.
The program should also display a message to students who have not enrolled in any classes: “You are not enrolled in any classes right now.”
NOTE: You must use the variables included in the code snippet get credit for this question.
import java.util.Scanner;
class Main {
public static void main(String[] args) {
int creditHours;
int fees = 0;
Scanner myScanner = new Scanner(System.in);
System.out.print("Please enter the number of credit hours you are taking this term: "); creditHours = myScanner.nextInt();
myScanner.close();
//YOUR CODE GOES HERE
} }
Break the Problem Down
Answer the following questions, then use the information to write your code.
What are the inputs in the pseudocode above? (INPUT)
What are we storing in the pseudocode above? (MEMORY)
What calculations are needed? (PROCESSES)
What needs to be displayed to the user?
(OUTPUT)
How many conditions are there in your problem statement?
What are they?
Does something need to happen if the condition(s) are not met?
What type of conditional statement do you need?
Solution in Java
Problem 2: Block Tuition
The cost of KSU’s tuition is determined by the number of credit hours a student enrolls in.
Using the chart below, write a conditional statement (ONLY) that sets the value of a tuition variable to what that student will owe.
NOTE: For this problem you can assume that all students are enrolled in a minimum of 12 hours.
Number of Credit Hours 12
13
14
15 or more
Cost (in USD) $2224 $2410 $2595 $2718
Break the Problem Down
Answer the following questions, then use the information to write your code.
What do we need to store? (MEMORY)
What are the inputs in the problem statement above? (INPUT)
What calculations are needed? (PROCESSES)
What needs to be displayed to the user?
(OUTPUT)
How many conditions are there in your problem statement?
What are they?
Does something need to happen if the condition(s) are not met?
What type of conditional statement do you need?
Solution in Java
Problem 3: Class Standing
Undergraduate students will be classified based on the number of earned institutional hours.
• Freshman:
• Sophomore:
• Junior:
• Senior:
0 - 29 hours
30 - 59 hours 60 - 89 hours
90 hours or more
Write a complete program that prompts the user for the number of credit hours they have completed. Write a conditional statement that prints out their class standing based on the information they provided.
Sample Output
Break the Problem Down
Answer the following questions, then use the information to write your code.
What do we need to store? (MEMORY)
Please enter the number of credit hours you have earned: 29 You are a freshman.
What are the inputs in the problem statement above? (INPUT)
What calculations are needed? (PROCESSES)
What needs to be displayed to the user?
(OUTPUT)
How many conditions are there in your problem statement?
What are they?
Does something need to happen if the condition(s) are not met?
What type of conditional statement do you need?
Solution in Java
Problem 4: Maximum Course Load
KSU’s policy on maximum course loads during the academic year is as follows:
A student in good standing may register for up to 18 hours. The Registrar may approve up to 21 hours for students with an institutional GPA of 3.5 or higher. Students
Write a complete program that prompts the user for the number of credit hours they have signed up for. Write the necessary conditional statement(s) to address the stipulations in KSU’s policy. Once the maximum number of hours is determined, display a message to the user that states “You may enroll in X credit hours this semester.” where X is the number of credit hours determined by your program.
Sample Output
Break the Problem Down
Answer the following questions, then use the information to write your code.
What do we need to store? (MEMORY)
Please enter your GPA: 3.75
You may enroll in up to 21 credit hours this semester.
What are the inputs in the problem statement above? (INPUT)
What calculations are needed? (PROCESSES)
What needs to be displayed to the user?
(OUTPUT)
How many conditions are there in your problem statement?
What are they?
Does something need to happen if the condition(s) are not met?
What type of conditional statement do you need?
Solution in Java
Problem 5: First-Year Seminar
All first-year full-time students entering Kennesaw State University with fewer than 15 semester hours are required to complete a First-Year Seminar. Students with 30 or more credit hours are not eligible to enroll in a First-Year Seminar.
Write a complete program that prompts the user for the number of credit hours they have completed. Write the necessary conditional statement(s) to address the stipulations in KSU’s policy.
When you run your program, it should display one of the following messages to the screen:
• You must enroll in First-Year Seminar.
• You do not have to take First-Year Seminar.
• You are not eligible for First-Year Seminar.
Sample Output
Break the Problem Down
Answer the following questions, then use the information to write your code.
What do we need to store? (MEMORY)
Enter the number of credit hours have you completed: 30
You are not eligible for First-Year Seminar.
What are the inputs in the problem statement above? (INPUT)
What calculations are needed? (PROCESSES)
What needs to be displayed to the user?
(OUTPUT)
How many conditions are there in your problem statement?
What are they?
Does something need to happen if the condition(s) are not met?
What type of conditional statement do you need?
Solution in Java
View More
4.I'm checking my answers for a practice ACT exam I did, and I am confused by this question on probability...
"As
...
lity...
"As part of a probability experiment, Elliott is to answer 4 multiple-choice questions. For each question, there are 3 possible answers, only 1 of which is correct. If Elliott randomly and independently answers each question, what is the probability that he will answer the 4 questions correctly?"
Solving the question I keep getting 1/256. My reasoning is that each question has a 1/4 chance of being right if you guessed, so 1/4 x 1/4 x 1/4 x 1/4 = 1/256.
But my answer choices are as follows, with the correct answer being E:
A. 27/81
B. 12/81
C. 4/81
D. 3/81
E. 1/81
Am I missing something? Or am I just completely solving this wrong?
View More
5.I need help getting started with my C++ assignment.
This is the prompt of the assignment and guidelines must follow.
...
delines must follow.
The purpose of this assignment is to give you practice using structs, using strings, writing functions and sorting. You will read a student file into an array of structs, determine grades, sort the array and print it out.
Program Steps and Requirements
Use the Student struct shown below.
Read the input file (partially shown below) and store the data in an array of structs. The input file contains 55 student records and one heading line.
Write code to determine the grade for each student. The grade determination is exactly as specified for this class in the syllabus. Remember to discard the lowest assignment grade.
Sort the array of student students in descending order by the total points.
Write the output file using the exact format shown below and include the two lines of headings in the output.
Required Student struct and named constants
const unsigned NumberOfStudents = 55;
const unsigned PointsPossible = 400;
const unsigned NumberOfAssignments = 10;
const unsigned NumberOfExercises = 10;
struct Student
{
int id;
string name;
int exercise[NumberOfExercises];
int assignment[NumberOfAssignments];
int midterm;
int final;
int codelab;
int exerciseTotal;
int assignmentTotal;
int totalPoints;
int percent;
string grade;
};
Input file
-StudId- -------Name-------- -----Exercises----- ---------Assignments--------- Mi Fin CL
12345678 Smartiepants, Sam 5 4 5 4 5 5 5 5 5 5 20 19 20 20 20 20 19 20 20 19 65 98 9
18519268 Mendoza, Victor 4 2 5 4 1 4 5 5 5 4 17 12 17 18 14 17 19 18 14 18 59 49 6
23276929 Chien, Shengfeng 2 3 0 4 4 5 2 5 5 2 9 18 15 8 19 18 18 16 19 13 64 89 8
18242679 Dhaliwal, Shawn 5 5 3 4 5 4 2 4 4 5 9 18 17 15 18 19 12 15 18 14 45 92 9
09869966 Miraftab, Mina 5 3 5 5 3 5 4 0 4 3 17 4 3 18 12 16 14 17 17 12 52 68 7
10930997 Dimas, Abraham 5 3 4 5 4 3 4 3 3 3 12 18 20 11 14 7 15 10 18 15 64 89 6
11545560 Masongsong, Mikhael 1 3 5 4 3 4 5 3 5 5 19 19 9 13 17 20 20 14 14 19 64 96 8
10626377 Zigler, Joshua 4 3 4 3 2 5 4 4 4 5 17 14 18 20 17 18 12 19 14 14 51 90 5
...
Output report file
Stud Id Name Ex Ass Mi Fin CL Tot Pct Gr
-------- ------------------- -- --- -- --- -- --- --- --
12345678 Smartiepants, Sam 48 178 65 98 9 398 100 A+
11545560 Masongsong, Mikhael 38 155 64 96 8 361 90 A-
20767544 Martins, Gustavo 40 144 67 97 10 358 90 A-
23305464 Zumwalt, Jacob 37 160 62 90 8 357 89 B+
23579439 Feirstein, Berent 42 159 55 91 9 356 89 B+
14965959 Ho, Brandon 40 157 66 84 8 355 89 B+
19988142 Wang, Lu 31 157 58 98 9 353 88 B+
09559062 Mora, Gabriel 36 137 67 100 7 347 87 B
19108176 Bailey, Tanequa 44 152 56 85 8 345 86 B
Suggested main function
int main()
{
Student students[NumberOfStudents];
getStudentDataFromFile(students, InputFilename);
determineGrades(students);
sort(students);
printStudentDataToFile(students,OutputFilename);
}
View More
6.Plagiarism is the presentation of the words, ideas, or opinions of someone else as your own. (2) You are guilty
...
are guilty of plagiarism if you submit as your own the words, ideas, or arrangement of material found in sources, such as books, magazines, or pamphlets (including Cliff's Notes), without crediting the source. (3) The ideas and opinions of someone else, even though expressed in your own words, must be acknowledged in the text or in a footnote. (4) You are also guilty of cheating/plagiarism if you copy the work of a fellow student, friend, or relative who is no longer in school or an essay from an internet source and submit it as your own. (5) A student who allows such copying is also guilty of plagiarism.
(6) Penalties English classes for cheating/plagiarism include:
an F grade (0) for the work involved:
an automatic F in conduct;
oral and/or written reprimands and/or referrals that will become part of your permanent record.
(7) Colleges and universities don't play around with kids who plagiarize. (8) A student at the state university was accused of plagiarism last year. (9) The practice of obtaining essays from internet sources is increasing. (10) In order to protect the validity of a degree. (11) Colleges are taking serious measures to punish those students who "buy" papers. (12)Two common penalties are suspension and expulsion. (13) A guilty student may be suspended for a certain amount of time (a year or a semester). (14) If a student is expelled, he/she may never again return to that institution or to any accredited college or university in the nation.
Question:
Read this text to identify one example of plagiarism. Then identify one consequence of plagiarism at the college level. Be sure your response uses examples from the text.
View More
7.I Need a tutor who is experienced in teaching Core plus math course 3. Need explanation and practice of question
...
of question from the chapter. If the student shows progress it is very likely that we will need at least weekly tutoring.
The Topic is inequalities and linear programming.
Please find attached the material:
-cmic unit is the chapter they are studying,
- Core linear programming is questions on the chapter.
- U2 Exam. will need help in answering the questions:
Please read the material carefully and tell me how much time is needed to make the best use of this time to explain the and go over the examples.
How long it takes to have the student review her work with you.
View More