I'm trying to find the total of two given number arrays for my assignment, but I keep receiving the error:
Cannot implicitly convert type 'double' to 'int'. An explicit conversion exists (are you missing a cast?)
int[] firstarray= new int[4] { 4, 20, 60, 150 };
double[] secondarray= new double[4] { 5, 40.5, 65.4, 145.98 };
firstarray[0] = 20;
secondarray[1] = 5;
int totalarrays = firstarray[0] + secondarray[1];
Console.WriteLine("Total of the two arrays " + totalarrays);