mmanchev23_it-career/09. Algorithms and Data Structures (Advanced)/08. Sample Exam/Solution/08. Sample Exam 2/ExamModule9Zad2/Program.cs
using System;

namespace ExamModule9Zad2
{
    class Program
    {
        static void Main(string[] args)
        {
            int m = int.Parse(Console.ReadLine());
            int n = int.Parse(Console.ReadLine());
            Console.WriteLine(mult(m, n));
        }
        
        public static int mult(int m, int n)
        {
            if (n == 1)
            {
                return m;
            }
            else
            {
                return mult(m, n - 1) + m;
            }
        }
    }
}
