Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Type win
//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; namespace Rextester { public class Color { public string color; } public class Program { static public bool pl = true; static public bool wn = false; public static void Main(string[] args) { int count = 0; int count1 = 0; Color varColor = new Color(); List<Color> lColorTemp = new List<Color>() ; List<String> lStr = new List<String>() ; lStr.Add("1"); List<Color> lColor = new List<Color>(); lColor.Add(new Color {color = "red"}); lColor.Add(new Color {color = "blue"}); lColor.Add(new Color {color = "green"}); lColor.Add(new Color {color = "black"}); lColor.Add(new Color {color = "black"}); lColor.Add(new Color {color = "red"}); var f = lColor.First().color; lColorTemp.Add(new Color {color = f}); while (count < 10) { count = 0; foreach (Color l in lColor) { // Console.WriteLine(" номер = " + l.color.Trim()); if (l.color != f) { Console.WriteLine(" wn = false = " + l.color ); l.color = f; count++; count1++; } } if (count == 0) { wn = true; Console.WriteLine(" wn = {0} | count = {1}", wn, count1); break; } } } } }
run
|
edit
|
history
|
help
0
bla bla
LCM and GCD
Exemplu OOP inventar
show IP
Polymorphism example
default branch name
Anagrams String
test examen
Learning Rounding and Truncation from the Maths library
Trading