1 Creates a HomeworkAssignment class 2 instantiates two objects The provided file has 3 and prompts the user for information about two courses syntax and/or logical 4ing static System.Console; errors. Determine the 5 ass DebugNinel problem(s) and fix the 7 static void Main() 8 { HomeworkAssignment coursel = new HomeworkAssignment(); HomeworkAssignment course2 = new HomeworkAssignment(); program. 10 11 12 13 string entryString; int exercises; // Get info for first class Write("What class do you have homework for? "); 14 15 16 entry = ReadLine(); 17 18 19 20 coursel.className = entryString; Write("How many exercises must you complete? "); entryString = ReadLine(entry); int.TryParse(entryString, exercises); 21 22 exercises = coursel.NumberOfExercises; 23 24 // Get info for another class Write("What class do you have homework for? "); entryString = ReadLine (); 25 26 27 course2.className = entrystring; 28 29 30 Write("How many exercises must you complete? "); entryString = ReadLine(); char. TryParse(entryString, exercises); course2.NumberOfExercises = exercises; 31 32 33 34 Writeline ("You have {0} minutes of homework for {1}", coursel.timeToComplete, coursel.ClassName); Writeline ("and {0} more minutes for {1}", 35 36 } 37 38 ass HomeworkAssignment course2.timeToComplete, course2.ClassName); 39 40 private int numberofExercises; 41 private int timeToComplete; 42 // 10 minutes to complete each exercise 43 private const int TIME_PER_EXERCISE = 10; 44 public ClassName {get; set}; 45 public int NumberOfExercises 46 { 47 get 48 49 50 51 { return numberOfexercises; } set 52 53 numberofExercises = number; 54 55 56 } 57 public double TimeToComplete 58 { 59 60 61 62 63 } 64 private void CalcCompletionTime() 65 { 66 CalcCompletionTime(); get { return timeToComplete; timeToComplete = numberofExercises * TIME_PER_EXERCISE
1 Creates a HomeworkAssignment class 2 instantiates two objects The provided file has 3 and prompts the user for information about two courses syntax and/or logical 4ing static System.Console; errors. Determine the 5 ass DebugNinel problem(s) and fix the 7 static void Main() 8 { HomeworkAssignment coursel = new HomeworkAssignment(); HomeworkAssignment course2 = new HomeworkAssignment(); program. 10 11 12 13 string entryString; int exercises; // Get info for first class Write("What class do you have homework for? "); 14 15 16 entry = ReadLine(); 17 18 19 20 coursel.className = entryString; Write("How many exercises must you complete? "); entryString = ReadLine(entry); int.TryParse(entryString, exercises); 21 22 exercises = coursel.NumberOfExercises; 23 24 // Get info for another class Write("What class do you have homework for? "); entryString = ReadLine (); 25 26 27 course2.className = entrystring; 28 29 30 Write("How many exercises must you complete? "); entryString = ReadLine(); char. TryParse(entryString, exercises); course2.NumberOfExercises = exercises; 31 32 33 34 Writeline ("You have {0} minutes of homework for {1}", coursel.timeToComplete, coursel.ClassName); Writeline ("and {0} more minutes for {1}", 35 36 } 37 38 ass HomeworkAssignment course2.timeToComplete, course2.ClassName); 39 40 private int numberofExercises; 41 private int timeToComplete; 42 // 10 minutes to complete each exercise 43 private const int TIME_PER_EXERCISE = 10; 44 public ClassName {get; set}; 45 public int NumberOfExercises 46 { 47 get 48 49 50 51 { return numberOfexercises; } set 52 53 numberofExercises = number; 54 55 56 } 57 public double TimeToComplete 58 { 59 60 61 62 63 } 64 private void CalcCompletionTime() 65 { 66 CalcCompletionTime(); get { return timeToComplete; timeToComplete = numberofExercises * TIME_PER_EXERCISE
Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
Related questions
Question

Transcribed Image Text:Instructions
DebugNine1.cs
+
1 Creates a HomeworkAssignment class
2 instantiates two objects
The provided file has
3 and prompts the user for information about two courses
syntax and/or logical
4 ing static System.Console;
errors. Determine the
5 ass DebugNinel
problem(s) and fix the
7 static void Main()
program.
8 {
HomeworkAssignment coursel = new HomeworkAssignment();
HomeworkAssignment course2 = new HomeworkAssignment();
10
11
12
string entrySstring;
int exercises;
13
14
// Get info for first class
Write("What class do you have homework for? ");
15
16
entry = ReadLine();
17
18
coursel.className = entryString;
Write("How many exercises must you complete? ");
entryString = ReadLine(entry);
int.TryParse (entryString, exercises);
19
20
21
22
23
24
25
exercises = coursel.NumberOfExercises;
// Get info for another class
Write("What class do you have homework for? ");
entryString = ReadLine();
26
course2.className = entrystring;
27
Write("How many exercises must you complete? ");
28
29
entryString = ReadLine();
char. TryParse(entryString, exercises);
30
31
32
33
34
course2.NumberofExercises = exercises;
Writeline ("You have {0} minutes of homework for {1}",
coursel.timeToComplete, coursel.ClassName);
Writeline("and {0} more minutes for {1}",
course2.timeToComplete, course2.ClassName);
36 }
37
38 ass HomeworkAssignment
39
40 private int numberofExercises;
41 private int timeToComplete;
42 // 10 minutes to complete each exercise
43 private const int TIME_PER_EXERCISE = 10;
44 public ClassName {get; set};
45 public int NumberofExercises
46 {
47
get
48
{
49
50
return numberOfexercises;
}
51
52
set
53
numberofExercises = number;
54
55
56 }
57 public double TimeToComplete
58 {
59
60
CalcCompletionTime();
get
{
61
62
63 }
64 private void CalcCompletionTime()
65 {
66
return timeToComplete;
}
timeToComplete = numberofExercises * TIME_PER_EXERCISE,
67 }
Expert Solution

This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
This is a popular solution!
Trending now
This is a popular solution!
Step by step
Solved in 2 steps

Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Recommended textbooks for you

Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education

Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON

Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON

Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education

Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON

Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON

C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON

Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning

Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education
Expert Answers to Latest Homework Questions
Q: what is the present value of the note
Q: Summit Manufacturing has annual fixed costs totaling
$140,000 and variable costs of $4 per unit.…
Q: Davidson Corp., which began business at the start of the current year, had the following data:
.…
Q: What is A & B?
Q: Financial Accounting
Q: provide answer General accounting question
Q: Benton Manufacturing uses a job-order costing system and last period incurred
$95,000 of actual…
Q: I need help with this problem and accounting question
Q: None
Q: Solve this financial accounting issue
Q: Help me tutor
Q: what is the applied factory overhead for job 457
Q: Assuming net operating losses are carried forward
Q: need true answer General accounting
Q: I'm waiting for answer
Q: please post this question in Account tutors feed
Q: Give correct answer this financial accounting question
Q: Calculate Return on Equity (ROE) using the DuPont formula
Q: Please given answer accounting question
Q: ?!
Q: Hello tutor provide answer this general accounting question