//Create a simple program that stores the values of 2 variables,//Then perfoms the following operations and store the results in //at least one other variable://-Addition//-Substration//-Multiplication//Preprocessor Directives//#include ‘StdAfx.h’#include
#include
using namespace std;//Global Declarations//Create my variables (Declaration)//*** Create variables to hold valuesdouble Variable1;double Variable2;//*** Create variable (s) to hold the result of the operationsdouble OperationResult1, OperationResult2, OperationResult3;//Function Declarationsfloat Addition_Operation();//Define an object for a simple calculatorclass Simple_Calculator{public://Data membersdouble Variable1;double Variable2;double Result;//Function Set-UP: Initialize your data membersint Set_Up(){Variable1 = 4;Variable2 = 6;Result = 0;}//Methods (members)double Addition(){//Perform Addition //*** Add Variable1 and Variable2 and save the resultResult = Variable1 + Variable2;//*** Output the result on the screencout << ‘The resulf of the Addition of ‘ << Variable1 << ‘ + ‘ << Variable2 << ‘ is ‘ << Result << ‘n’;}double Substraction(){}double Multiplication(){}};//Main Functionint main() {//Use Algorithm to outline the series of steps required to solve your problem//Algorithm: Structure Chart, Pseudocode, Flowchart//Create an object of type Simple_CalculatorSimple_Calculator myCalculator;myCalculator.Set_Up();myCalculator.Addition();//Assign values to my variablesVariable1 = 25;Variable2 = 00;//Call the Addition function: Function CallAddition_Operation();//Perform Substration Operation//*** Substract Variable2 from Variable1 and save the result: Substract Operands from one anotherOperationResult2 = Variable1 – Variable2;//*** Output the result of the operation on the screencout << ‘The resulf of the Substration of ‘ << Variable1 << ‘ – ‘ << Variable2 << ‘ is ‘ << OperationResult2 << endl;//Perform Multiplication Operation//*** Multi;ply Variable2 by Variable1 and save the resultOperationResult3 = Variable1 = Variable2;//*** Output the result of the operation on the screencout << ‘The resulf of the Multiplication of ‘ << Variable1 << ‘ * ‘ << Variable2 << ‘ is ‘ << OperationResult3 << endl;return 0;}//Other Function Definitions//Addition functionfloat Addition_Operation(){//Perform Addition //*** Add Variable1 and Variable2 and save the resultOperationResult1 = Variable1 + Variable2;//*** Output the result on the screencout << ‘The resulf of the Addition of ‘ << Variable1 << ‘ + ‘ << Variable2 << ‘ is ‘ << OperationResult1 << ‘n’;}//Other Function Definition
Consider Your Assignments Done
See Why Our Clients Hire Us Again And Again!
Success Guarantee
When you order form the best, some of your greatest problems as a student are solved!








Jermaine Byrant
Nicole Johnson



