Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

missing a braces somewhere using System; using static System.Console; using System.Globalization; class SalesTransactionDemo { static void Main ( ) { private string name; private double

missing a braces somewhere
using System;
using static System.Console;
using System.Globalization;
class SalesTransactionDemo
{
static void Main()
{
private string name;
private double salesAmount;
private double commission;
public SalesTransactionDemo(string name, double salesAmount, double rate)
{
this.name = name;
this.salesAmount = salesAmount;
this.commission = salesAmount * rate;
}
public SalesTransactionDemo(string name, double salesAmount)
{
this.name = name;
this.salesAmount = salesAmount;
this.commission =0;
}
public SalesTransactionDemo(string name)
{
this.name = name;
this.salesAmount =0;
this.commission =0;
}
public static double GetRate()
{
return RATE;
}
{
string name_all = $"{change_1.name} and {change_2.name}";
double SalesAmount_all = change_1.salesAmount + change_2.salesAmount;
return new SalesTransactionDemo(name_all, SalesAmount_all, RATE);
}
public void Display()
{
WriteLine("Salesperson: {0}", name);
WriteLine("Sales Amount: {0}", salesAmount.ToString("C", CultureInfo.GetCultureInfo("en-US")));
WriteLine("Commission: {0}", commission.ToString("C", CultureInfo.GetCultureInfo("en-US")));
WriteLine("Commission Rate: {0}", RATE.ToString("P", CultureInfo.InvariantCulture));
WriteLine();
}
// Write your code here
}
}
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions