Dictionary(2)
-
C# 15649번 N과 M(1)
코드 : using System; using System.Text; namespace beakjoon { class _2 { static int range, length; // 값 출력을 위한 정수 배열 static int[] arr = new int[9]; // 배열이 오름차순인지 확인하기 위한 배열 static int[] arrSort = new int[9]; // 중복 제거를 위한 bool 배열 static bool[] visited = new bool[9]; // 한번이라도 쓴적이 있는지를 확인하기 위한 bool 배열 static bool[] isUsed = new bool[9]; //DFS 알고리즘 public static void DFS(int cnt) { // 출력할 배열이 완성되면 문자열 ..
2022.01.17 -
C# 18870번 좌표 압축
코드 : using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace _10 { class Program { static void Main(string[] args) { StringBuilder sb = new StringBuilder(); int N = Convert.ToInt32(Console.ReadLine()); //회원 수 int[] array = new int[N]; int[] check = new int[N]; int[] output = new int[N]; int rank = 0; string input = Console.Rea..
2022.01.10