There are at least five (probably more) places in the attachedC# program code that could be optimized. Find at least five thingsin the Program.cs file that can be changed to makethe program as efficient as possible.
- List five problems you found with the code (Put your listeither in comments within the code or in a separate Word or textdocument), and then optimize the code in the attached code below tomake it as efficient as possible. The program output must not beaffected by your changes. To the user it should still do everythingit did before your changes provided the user enters validdata.
using System;
namespace COMS_340_L4A
{
class Program
{
static void Main(string[] args)
{
Console.Write(\"How many doughnuts do you need for the firstconvention? \");
int.TryParse(Console.ReadLine(), out int total1);
Console.Write(\"How many doughnuts do you need for the secondconvention? \");
int.TryParse(Console.ReadLine(), out int total2);
int totalDonuts = Calculator.CalculateSum(new int[] { total1,total2 });
Console.WriteLine($\"{ totalDonuts } doughnuts is {Calculator.ConvertToDozen(totalDonuts)} dozen.\");
Console.WriteLine(\"Press Enter to quit...\");
Console.ReadLine();
}
}
static class Calculator
{
static int DOZEN = 12;
public static int CalculateSum(int[] args)
{
int return_value = 0;
foreach (int i in args)
{
return_value += i;
}
return return_value;
}
public static int ConvertToDozen(int total)
{
int dozen = DOZEN;
return total / dozen;
}
}
}