일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
- Git
- 유노코딩
- JavaScript
- 코딩테스트
- HTML
- 꿀단집
- MySQL
- 99클럽
- 항해99
- aws
- 개발자취업
- 방송대컴퓨터과학과
- redis
- 코딩테스트준비
- Python
- presignedurl
- nestjs
- 엘리스sw트랙
- 중간이들
- 파이썬
- 방송대
- Cookie
- node.js
- 프로그래머스
- SQL
- 파이썬프로그래밍기초
- TiL
- 코드잇
- CSS
- 데이터베이스시스템
- Today
- Total
목록항해99 (36)
배꼽파지 않도록 잘 개발해요

Find if Path Exists in Graph출처 : LeetCodeThere is a bi-directional graph with n vertices, where each vertex is labeled from 0 to n-1 (inclusive). The edges in the graph are represented as a 2D integer array edges, where each edges[i] = [ui, vi] denotes a bi-directional edge between vertex ui and vertex vi. Every vertex pair is connected by at most one edge, and no vertex has an edge to itself. Y..

광복절을 맞이하여 코딩테스트 스터디를 운영하는 항해99에서 이벤트를 진행하였다. 주제인 광복절과 어울리는 아스키 아트 그림 한 장을 그려서 제출하는 것이었다. 할일은 많지만 이벤트에 참여하고 싶어서 한 개 만들어 보았다.만든 과정은 다음과 같다. 이미지 출처 :https://blog.naver.com/PostView.nhn?blogId=jaidream4130&logNo=221610868183 처음에는 태극기, 무궁화, 독립기념물 등 광복절의 상징이 모두 담겨있는 서대문 독립공원을 갖고 그림을 그리려고 했다.하지만 이걸 아스키코드로 변환하였을 때 생각보다 원하는 만큼 또렷하게 나오지 않아서 다른 걸로 바꿨다.우선 아스키코드로 변환하기 이전에 Artguru한테 이 그림의 화풍을 명화처럼 바꿔달라고 해봤다. ..

Find Center of Star Graph출처 : LeetCodeThere is an undirected star graph consisting of n nodes labeled from 1 to n. A star graph is a graph where there is one center node and exactly n - 1 edges that connect the center node with every other node. You are given a 2D integer array edges where each edges[i] = [ui, vi] indicates that there is an edge between the nodes ui and vi. Return the center of ..

Array Partition출처 : LeetCodeGiven an integer array nums of 2n integers, group these integers into n pairs (a1, b1), (a2, b2), ..., (an, bn) such that the sum of min(ai, bi) for all i is maximized. Return the maximized sum. Example 1: Input: nums = [1,4,3,2]Output: 4Explanation: All possible pairings (ignoring the ordering of elements) are:1. (1, 4), (2, 3) -> min(1, 4) + min(2, 3) = 1 + 2 = 32. ..

/** * @param {number} rowIndex * @return {number[]} */var getRow = function(rowIndex) { const row = [1]; for (let j = 1; j

/** * @param {number} numRows * @return {number[][]} */function generate(numRows) { // 첫 번째 행을 포함한 삼각형 초기화 const triangle = [[1]]; // 두 번째 행부터 numRows까지 각 행을 생성 for (let i = 1; i

function solution(n, lost, reserve) { // 여분의 체육복이 있는 학생과 잃어버린 학생의 교집합을 제거 let _lost = lost.filter(student => !reserve.includes(student)); let _reserve = reserve.filter(student => !lost.includes(student)); // 순서대로 정렬해주기 _lost = _lost.sort((a, b) => b - a); _reserve = _reserve.sort((a, b) => b - a); // 여분의 체육복을 가진 학생이 잃어버린 학생에게 체육복을 빌려줄 수 있는지 확인 for (let i = 0; i

function solution(k, m, score) { // m개씩 묶고, 1부터 k까지 있음. // score 내림차순 정렬, 크기가 m인 배열을 만들어서 순서대로 넣는다 // 이때 score에서 m개씩 나눴을 때 나머지는 버림. // 계산할 때는 크기가 m인 각 배열의 최저 점수 x m X 1 let answer = 0; // 각 배열마다의 점수 const sortedScore = score.sort((a, b) => b - a); for (let i = 0; i

// Interface for a binary tree node.interface TreeNode { val: number; left: TreeNode | null; right: TreeNode | null;}// Function to create a new TreeNode with a specific value.function createTreeNode(val: number, left: TreeNode | null = null, right: TreeNode | null = null): TreeNode { return { val: val, left: left, right: right };}let previousNode: TreeNode | ..

Binary Tree Inorder Traversal출처 : LeetCodeGiven the root of a binary tree, return the inorder traversal of its nodes' values. Example 1: Input: root = [1,null,2,3] Output: [1,3,2]Example 2:Input: root = [] Output: []Example 3:Input: root = [1] Output: [1] Constraints:The number of nodes in the tree is in the range [0, 100]. -100 오늘도 즐거운 리트코드 문제풀이 시간이다. 배열 문제를 주로 풀다가 트리 문제를 접하게 되니 접근 방식이 달라서 어렵..