목록C# (36)
유니티3D 프로그래밍

DFS using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Study02 { public class App { //생성자 public App() { Graph g = new Graph(); var A = g.AddVertex("A"); var B = g.AddVertex("B"); var C = g.AddVertex("C"); var D = g.AddVertex("D"); var E = g.AddVertex("E"); var F = g.AddVertex("F"); var G = g.AddVertex("G"); g.AddEdge(A, ..

Binary Search Tree using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Study02 { public class App { //생성자 public App() { Console.WriteLine("App"); BST bst = new BST(); bst.Add(30); bst.Add(25); bst.Add(35); bst.Add(21); bst.Add(19); bst.Add(23); var target = 25; Console.WriteLine("target: {0}", target); var result = bst.Se..

BinaryTree 연습 using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Study02 { public class App { //생성자 public App() { Console.WriteLine("App"); BinaryTree tree = new BinaryTree("A"); tree.root.left = new BinaryTreeNode("B"); tree.root.right = new BinaryTreeNode("C"); tree.root.left.left = new BinaryTreeNode("D"); tree.root.l..

LCRSTree using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Study02 { public class App { public App() { Console.WriteLine("App"); LCRSTree tree = new LCRSTree("A"); LCRSNode A = tree.root; LCRSNode B = tree.AddChild(A, "B"); tree.AddChild(A, "C"); //B의 형제로 D를 추가 var D = tree.AddSibiling(B, "D"); tree.AddChild(B, "E"); tre..
App using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Study00 { public class App { public App() { Console.WriteLine("App"); string itemPath = "./item_data.json"; DataManager.Instance.LoadData(itemPath); Login login = new Login(); Tutorial tutorial = new Tutorial(); } } } Login using Newtonsoft.Json; using System; using S..

단일 연결 리스트 연습 using System; using System.Diagnostics; using System.Linq; using System.Threading; using System.Threading.Tasks; namespace Study00 { public class App { //생성자 public App() { SingleLinkedList list = new SingleLinkedList(); var head = new Node(1); list.Add(head); list.Add(new Node(2)); var node3 = new Node(3); list.AddAfter(head, node3); list.Print(); Console.WriteLine("---------------..

쿠키런 게임 캐릭터 선택 using System; using System.IO; using Newtonsoft.Json; using System.Collections.Generic; using System.Linq; using System.Threading; namespace Study01 { public class App { public App() { Console.WriteLine("App"); GameInfo gameInfo = null; string dataPath = "./cookie_data.json"; string infoPath = "./game_info.json"; //json파일 읽기 string json = File.ReadAllText(dataPath); Console.WriteLi..

JSON 복습 using System; using System.IO; using Newtonsoft.Json; using System.Collections.Generic; using System.Linq; namespace Study01 { public class App { public App() { Console.WriteLine("App"); string txt1 = File.ReadAllText("./ItemData.json"); string txt2 = File.ReadAllText("./Item_Grade.json"); Console.WriteLine(txt1); //역직렬화 ItemGrade[] itemGrades = JsonConvert.DeserializeObject(txt2); ItemD..