A program that will ask the user to give three numbers and then the program will compute the sum of three numbers using a function in C# programming language.
I am currently accepting programming work, IT projects, school and application development, programming projects, thesis and capstone projects, IT consulting work, computer tutorials, and web development work kindly contact me in the following email address for further details. If you want to advertise on my website kindly contact me also in my email address also. Thank you.
My email address is the following jakerpomperada@gmail.com, jakerpomperada@aol.com, and jakerpomperada@yahoo.com.
My mobile number here in the Philippines is 09173084360.
Please subscribe to my channel https://www.youtube.com/channel/UCOs-lpOoIeJoh6gpJthPoGg
Program Listingusing System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ConsoleApplication1 { class Program { public static int Addition_Three_Numbers(int num1, int num2, int num3) { int total_sum = (num1 + num2 + num3); return total_sum; } static void Main(string[] args) { int num1, num2, num3, sum; Console.WriteLine("\n"); Console.Write("\tAddition of Three Numbers Using Functions in C#"); Console.WriteLine("\n"); Console.Write("\tGive First Value : "); num1 = Convert.ToInt32(Console.ReadLine()); Console.Write("\tGive Second Value : "); num2 = Convert.ToInt32(Console.ReadLine()); Console.Write("\tGive Third Value : "); num3 = Convert.ToInt32(Console.ReadLine()); sum = Addition_Three_Numbers(num1, num2, num3); Console.WriteLine(); Console.WriteLine("\tThe Total Sum is " + sum + "."); Console.WriteLine(); Console.WriteLine("\tEnd of Program"); Console.WriteLine(); Console.ReadKey(); } } }
No comments:
Post a Comment