예제 #1
0
파일: Program.cs 프로젝트: m17guy/homework
        static void takemoney(object o)
        {
            bankacount person = (bankacount)o;

            person.withdroul(50);
            Console.WriteLine(person.getbalance());
        }
예제 #2
0
파일: Program.cs 프로젝트: m17guy/homework
        static void Main(string[] args)
        {
            Console.Title = "guy"; //just for fun

            bankacount couple = new bankacount();
            Thread     wife   = new Thread(takemoney);

            wife.Start(couple);
            couple.withdroul(50);
            Console.WriteLine(couple.getbalance());



            Console.ReadLine();
        }