in c # i need to Add an operator*() method to the Fraction class created in Programming Exercise 11a so that it correctly multiplies two Fractions. The result should be in proper, reduced format. Demonstrate that the method works correctly in a program named FractionDemo2. Tasks The Fraction class operator*() method defined for Fraction class my code is  using static System.Console; class FractionDemo2 {    static void Main()    {      // Write your main here    }     }

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter11: Inheritance And Composition
Section: Chapter Questions
Problem 6PE
icon
Related questions
Question

in c # i need to

Add an operator*() method to the Fraction class created in Programming Exercise 11a so that it correctly multiplies two Fractions. The result should be in proper, reduced format. Demonstrate that the method works correctly in a program named FractionDemo2.

Tasks

The Fraction class operator*() method defined for Fraction class

my code is 

using static System.Console;
class FractionDemo2
{
   static void Main()
   {
     // Write your main here
   }    
}
Expert Solution
Step 1 Introduction

In C#, a method which refers one it is a code block that contains a series of statements . A program causes the statements to be executed by calling the method and passing in any required parameters. A method must have a return type, a method name, optional parameters, and a method body. The return type specifies what type of value the method will return, and the method name is an identifier that is used to refer to the method. The optional parameters which usually specify data that can be passed into the method, and the method body is the code that will be executed when the method is called.

trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 4 steps

Blurred answer
Knowledge Booster
Reference Types in Function
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.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning
C++ for Engineers and Scientists
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr