본문 바로가기
반응형

코딩테스트 준비/백준 C#161

백준 C# - 11005 +) 풀이 관련문제 보러 가기 백준 C# - 2745 using System; using System.Collections.Generic; namespace baek2 { class Program { static void Main(string[] args) { string input = Console.ReadLine(); string[] token = input.Split(); string n = token[0]; int m = int.Parse(token[1]); Dictionary dic = new Di code-piggy.tistory.com 풀이 01 Dictionay부분은 위의 2745 참조 02 반복문을 통해서 B진법으로 바꾸기 while (div>0) { int remainder = div % m; s.. 2023. 5. 25.
백준 C# - 2745 관련문제 보러가기 백준 C# - 11005 +) 풀이 관련문제 보러 가기 백준 C# - 2745 using System; using System.Collections.Generic; namespace baek2 { class Program { static void Main(string[] args) { string input = Console.ReadLine(); string[] token = input.Split(); string n = token[0]; int m = code-piggy.tistory.com using System; using System.Collections.Generic; namespace baek2 { class Program { static void Main(string[] a.. 2023. 5. 25.
백준 C# - 2563 +) 풀이 1. 풀이 01 가로, 세로의 크기가 각각 100인 정사각형 모양의 도화지 만들기 int[,] array = new int[100, 100]; 02 색종이 수 입력 받기 int n = int.Parse(Console.ReadLine()); 03 색종이 붙일 위치 입력 받기 for (int i = 0; i < n; i++) { string input = Console.ReadLine(); string[] token = input.Split(); int x = int.Parse(token[0]); int y = int.Parse(token[1]); } 04 도화지에 색칠하기 for (int j = x; j < x + 10; j++) { int num = 0; for (int w = y; w < y + 10;.. 2023. 5. 18.
백준 C# - 10798 2차원 배열 알아보러가기 C# - 2차원 배열 1. 초기화 및 값 할당 방법 int [,] = new int [3,3]; 01 초기화 구문을 사용하여 값 할당 int[,] array = new int[,]{ { 1 , 2 , 3 } , { 4 , 5 , 6 } , { 7 , 8 , 9 } }; 02 인덱스를 사용하여 값 할당 array[0,1] = 1; array[0,2] = 2; a code-piggy.tistory.com using System; using System.Collections.Generic; namespace baek2 { class Program { static void Main(string[] args) { string[,] array = new string[5,15]; for (i.. 2023. 5. 18.
백준 C# - 2566 2차원 배열 알아보러 가기 C# - 2차원 배열 1. 초기화 및 값 할당 방법 int [,] = new int [3,3]; 01 초기화 구문을 사용하여 값 할당 int[,] array = new int[,]{ { 1 , 2 , 3 } , { 4 , 5 , 6 } , { 7 , 8 , 9 } }; 02 인덱스를 사용하여 값 할당 array[0,1] = 1; array[0,2] = 2; a code-piggy.tistory.com using System; using System.Collections.Generic; namespace baek2 { class Program { static void Main(string[] args) { int max = 0; int[,] array = new int[9, 9].. 2023. 5. 17.
백준 C# - 2738 2차원 배열 알아보러 가기 C# - 2차원 배열 1. 초기화 및 값 할당 방법 int [,] = new int [3,3]; 01 초기화 구문을 사용하여 값 할당 int[,] array = new int[,]{ { 1 , 2 , 3 } , { 4 , 5 , 6 } , { 7 , 8 , 9 } }; 02 인덱스를 사용하여 값 할당 array[0,1] = 1; array[0,2] = 2; a code-piggy.tistory.com using System; using System.Collections.Generic; using System.Text; namespace baek2 { class Program { static void Main(string[] args) { string s = Console.Rea.. 2023. 5. 15.
반응형