Answered step by step
Verified Expert Solution
Question
1 Approved Answer
-------------------------------------------------------------------------------------------------------------------------------------------------------------------- -------------------------------------------------------------------------------------------------------------------------------------------------------------------- - Find the syntax errors in each of these blocks of code. Determine the problem and fix the program. // GetData() method accepts
--------------------------------------------------------------------------------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------------------------------------------------------------
- Find the syntax errors in each of these blocks of code. Determine the problem and fix the program.
// GetData() method accepts order number and quantity // that are used in the Main) method /Price is $3.99 each using System; using static System.Console: class DebugEigh t1 static void Main () int orderNum, quantity; double total; const double PRICE EACH = 3.99; GetData (orderNum, quantity); t tal = quantity * PRICEEACH; WriteLine ("Order #(0). Quantity ordered = {1}", orderNum, quantity; WriteLine ("Total is (0", total.ToString ("C")) private static void GetData( utrder, ut amount) String sl, s2; write ( "Enter rder number "); s1 = ReadLine ; Write("Enter quantity "); s2 = ReadLine ; rder = Convert . ToInt32 (s1) ; amountConvert.ToInt32 (s2)Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started