using System;
using System.Windows.Forms;

namespace _7_23
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        public static int Fact(int n)
        {
            if (n <= 1)
                return 1;
            else
                return (n * Fact(n - 1));
        }

        private void button1_Click(object sender, EventArgs e)
        {
            int n = Convert.ToInt32(textBox1.Text);
            
            MessageBox.Show(n.ToString() + "!: " + Fact(n).ToString());
        }
    }
}