Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Volatile madness
//Rextester.Program.Main is the entry point for your code. Don't change it. //Compiler version 4.0.30319.17929 for Microsoft (R) .NET Framework 4.5 using System; using System.Collections.Generic; using System.Linq; using System.Text.RegularExpressions; using System.Threading; using System.Threading.Tasks; namespace Rextester { public class Program { # Дорогой фриман, убери слово volatile и поведение проги изменится, вот увидишь private volatile bool flag = true; private void run() { Task.Factory.StartNew(resetFlagAfter1s); int x = 0; while (flag)++x; Console.WriteLine("Done"); } private void resetFlagAfter1s() { Thread.Sleep(1000); flag = false; } public static void Main(String[] a) { new Program().run(); } } }
run
|
edit
|
history
|
help
0
Truncate String by Byte
String to Byte[] Conversion
Game_snake
Ok
Linear search vs. Binary search
Write a program to count the occurrence of each distinct item in the array?
Compress in C#
octalofint
F ?
lab6