Beispiel #1
0
        private void buttonSolveTask1_Click(object sender, EventArgs e)
        {
            int n = int.Parse(textBoxNTask1.Text);

            library solver = new library();
            double  sum    = solver.CalculateSum(n);

            labelTask1Result.Text = "Сума дорівнює = " + sum.ToString();
        }
Beispiel #2
0
        static void Main(string[] args)
        {
            Console.Write("Введiть число: ");
            int     n      = int.Parse(Console.ReadLine());
            library solver = new library();
            double  sum    = solver.CalculateSum(n);

            Console.WriteLine("Сума довiвнює = " + sum);
        }