/
code
89 lines (75 loc) · 2.16 KB
/
code
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
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApplication6
{
class Program
{
static void Main(string[] args)
{
int y = 0;
string ys = "";
int count = 0;
List<int> grArrList= new List<int>();
for (int j = 0; j < 1; )
{
Console.WriteLine("type numbers when you(0-9). When you feel done, type nothing");
ys = Console.ReadLine();
if (ys == "")
{
j = 1;
}
else
{
y = int.Parse(ys);
grArrList.Add(y);
count++;
}
}
Console.WriteLine(" ");
foreach (int element in grArrList)
{
Console.Write("|" + grArrList[element] + "| ");
}
Console.WriteLine(" ");
int k = 0;
List<List<string>> chart = new List<List<string>>() {new List<string>() {"| |"}};
int copy = 0;
int dif = 0;
for (int g = 0; g < 1; )
{
int n = 0;
while (n < count)
{
foreach (int element in grArrList)
{
if (grArrList[n] == element)
{
copy++;
chart[n][copy] = "|*|";
} else {
dif++;
}
}
n++;
}
if (n == count || n > count)
{
g = 1;
}
}
//Console.WriteLine(" ");
for (int q = 0; q < dif; q++)
{
for (int p = 0; p < copy; p++)
{
Console.Write(chart[dif][copy]);
}
Console.WriteLine();
}
}
}
}