-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCalculateHistory.cs
More file actions
31 lines (28 loc) · 906 Bytes
/
CalculateHistory.cs
File metadata and controls
31 lines (28 loc) · 906 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp20
{
internal class CalculateHistory
{
public int index { get; set; }
public string FirstOperand { get; set; }
public string SecondOperand { get; set; }
public string opertaor { get; set; }
public string Result { get; set; }
public string GetHistory()
{
return $"Calculate({index}). {FirstOperand} {opertaor} {SecondOperand} = {Result}";
}
public CalculateHistory(int index,string FirstOperand,string Operator,string SecondOperand,string Result)
{
this.index = index;
this.FirstOperand = FirstOperand;
this.SecondOperand = SecondOperand;
this.opertaor = Operator;
this.Result = Result;
}
}
}