Thread C# Tutorial

using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Reflection;
using System.Runtime;
using System.Runtime.CompilerServices;
using System.Security;
using System.Text;
using System.Threading;
public class MainClass
{
    private static int count = 0;
    private static object myMutex = new object();
    
    [MethodImpl(MethodImplOptions.Synchronized)]
    public static void Main()
    {
         count++;
    }
}