-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathProgram.cs
More file actions
101 lines (66 loc) · 2.45 KB
/
Program.cs
File metadata and controls
101 lines (66 loc) · 2.45 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using SystemProgramming.SyncThread;
using SystemProgramming.SyncThread.Lock;
using SystemProgramming.SyncThread.Mutex;
using SystemProgramming.SyncThread.Semaphore;
namespace SystemProgramming
{
class Program
{
static void Main(string[] args)
{
//ApplicationDomain.DomainInfo();
Console.Clear();
//ApplicationDomain.WorkWithDomain();
Console.Clear();
//ThreadInfo.SimpleThread();
Console.Clear();
//FewThread.StartFewThread();
Console.Clear();
//FewThread.StartFewThreadWithParameters();
Console.Clear();
//MultyParametersThread.StartMultyParametersThread();
Console.Clear();
//MultyParametersThreadBest counter = new MultyParametersThreadBest(1, 4);
//Thread myThread = new Thread(new ThreadStart(counter.Count));
//myThread.Start();
Console.Clear();
//SyncThreadBad.RunFewThreads();
Console.Clear();
//SyncThreadBest.RunFewThreads();
Console.Clear();
//ThreadJoin.Start();
Console.Clear();
//SyncThreadMonitor.RunFewThreads();
Console.Clear();
//TickTock tt = new TickTock();
//TickTockThread mt1 = new TickTockThread("Tick", tt);
//TickTockThread mt2 = new TickTockThread("Tock", tt);
//mt1.thrd.Join();
//mt2.thrd.Join();
//Console.WriteLine("Clock stopped");
//Console.ReadLine();
Console.Clear();
//IncThread mt1 = new IncThread("Inc thread", 5);
// разрешить инкременирующему потоку начаться
//Thread.Sleep(1);
//DecThread mt2 = new DecThread("Dec thread", 5);
//mt1.Thrd.Join();
//mt2.Thrd.Join();
//Console.ReadLine();
//Console.Clear();
//SemaphoreSync.Run();
//Console.Clear();
//App.Run();
int[] numbers = { 2, 172, 1, 77, 3, 91, 23, 73, 6, 3, 11, 384, 5};
MaxFinder finder = new MaxFinder(numbers);
Console.WriteLine(finder.FindMax());
Console.ReadLine();
}
}
}