C#/C#200제
[C#] 15일차 - 101. 큐를 이용한 프로그램
반나무
2021. 2. 13. 17:23
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace A100_QueueImplementation
{
class Program
{
static void Main(string[] args)
{
Random r = new Random();
MyQueue<float> que = new MyQueue<float>();
for (int i = 0; i < 5; i++)
que.EnQueue(new Node<float>(r.Next(100) / 100.0F));
que.Print();
for (int i = 0; i < 3; i++)
Console.WriteLine("DeQueue: {0}", que.DeQueue());
que.Print();
}
}
}
반응형