Volatile keyword in C#

Sourav.Kayal
Posted by Sourav.Kayal under C# category on | Points: 40 | Views : 1123
using System;
using System.Linq;
using System.Text;
using System.Collections;
using System.IO;
using System.Diagnostics;
using System.Collections.Generic;
using System.Data.SqlClient;
namespace BlogProject
{
class Test
{
public volatile int i = 100;
public Test(int _i)
{
i = _i;
Console.WriteLine(i);
}
}
class Program
{
static void Main(string[] args)
{
Test t = new Test(200);
Console.ReadLine();
}
}
}

Comments or Responses

Login to post response