sarang넘치는 코딩 공작소
close
프로필 배경
프로필 로고

sarang넘치는 코딩 공작소

  • 분류 전체보기 (106) N
    • Java (15)
    • SpringBoot (0)
    • 코딩테스트 (57) N
      • 개념정리 (7)
      • 문제풀이 (50) N
    • 자격증 (16) N
      • 정보처리기사 (12)
      • AWS Solution Architecture (4) N
    • JavaScript (1)
    • Vue.js (8)
    • 프로젝트 (1)
    • RabbitMQ (1)
    • Network (5) N
    • Database (2)
  • 홈
  • 태그
  • 방명록

[ 프로그래머스 ] #42892 : 길 찾기 게임 - JAVA

🔗 길 찾기 게임import java.util.*;class Solution { private static class Node{ int x; int y; int num; Node left; Node right; Node(int x, int y, int num){ this.x=x; this.y=y; this.num=num; } } private static Node makeTree(int [][] nodeinfo){ Node[] nodes=new Node[nodeinfo.length]; for(int i=0;i{ if(..

  • format_list_bulleted 코딩테스트/문제풀이
  • · 2025. 6. 5.
  • textsms

[ 프로그래머스 ] #72410 : 신규 아이디 추천 - JAVA

🔗 신규 아이디 추천class Solution { public String solution(String new_id) { // 3~15자 이하 // 알파벳 소문자, 숫자, -, _, . 가능 // 7 단계 아이디 규칙 검사, 맞지 않는 경우 새로운 아이디 추천 // new_id : 신규 유저가 입력한 아이디 // 1. 대문자 -> 소문자 new_id=new_id.toLowerCase(); // 2. 가능한 문자 제외 삭제 new_id = new_id.replaceAll("[^0-9a-z._-]", ""); // 3. .연속을 . 하나로 new_id = new_id.r..

  • format_list_bulleted 코딩테스트/문제풀이
  • · 2025. 5. 13.
  • textsms

[ 프로그래머스 ] #77486 : 다단계 칫솔 판매 - JAVA

🔗 다단계 칫솔 판매import java.util.Map;import java.util.HashMap;class Solution { public int[] solution(String[] enroll, String[] referral, String[] seller, int[] amount) { // 민호 : root node // 이익의 10%를 부모에게 주고 나머지는 자신이 가짐, 부모는 또 부모에게 10% 줌 // 10% 계산시 원단위 절사, 1원 미만인 경우 분배하지 않고 자신이 가짐 // enroll : 각 판매원의 이름을 담은 배열, 민호의 이름은 없음 // referral : i 번째에 있는 이름은 배열 enroll..

  • format_list_bulleted 코딩테스트/문제풀이
  • · 2025. 5. 12.
  • textsms

[ 프로그래머스 ] #12985 : 예상 대진표 - JAVA

:link: 예상 대진표class Solution{ public int solution(int n, int a, int b) { // n : 참가자 수 // a : 참가자 번호 // b : 경쟁자 번호 // 참가자는 경쟁자와 몇 번째 라운드에서 만나는지 return // a, b 의 참가자 번호가 같아 지면 만나는 것 int answer = 0; for(; a!=b;answer++){ a=(a+1)/2; b=(b+1)/2; } return answer; }}

  • format_list_bulleted 코딩테스트/문제풀이
  • · 2025. 5. 11.
  • textsms

[ 프로그래머스 ] #84512 : 모음사전 - JAVA

🔗 모음사전import java.util.*;class Solution { public int solution(String word) { // A : 0 // E : 1 // I : 2 // O : 3 // U : 4 int []weight=new int [5]; // 가중치 계산 for(int i=0;i map=new HashMap(); for(int i=0;i

  • format_list_bulleted 코딩테스트/문제풀이
  • · 2025. 5. 8.
  • textsms

[ 프로그래머스 ] #43163 : 단어 변환 - JAVA

🔗 단어 변환import java.util.*;class Solution { static boolean[] visited; static List list; static Deque queue; public int solution(String begin, String target, String[] words) { // 1. 한 번에 한 개의 알파벳 변경 // 2. words 에 있는 단어로만 변경 // begin -> target 으로 가는데 최소 몇 단계의 과정을 거쳐야 하는지 // 변환할 수 없는 경우는 0 return // 단어 리스트 list=new ArrayList(Arrays.asList(word..

  • format_list_bulleted 코딩테스트/문제풀이
  • · 2025. 5. 7.
  • textsms
  • navigate_before
  • 1
  • 2
  • 3
  • 4
  • ···
  • 10
  • navigate_next
공지사항
전체 카테고리
  • 분류 전체보기 (106) N
    • Java (15)
    • SpringBoot (0)
    • 코딩테스트 (57) N
      • 개념정리 (7)
      • 문제풀이 (50) N
    • 자격증 (16) N
      • 정보처리기사 (12)
      • AWS Solution Architecture (4) N
    • JavaScript (1)
    • Vue.js (8)
    • 프로젝트 (1)
    • RabbitMQ (1)
    • Network (5) N
    • Database (2)
최근 글
인기 글
최근 댓글
태그
  • #Stack
  • #queue
  • #bfs
  • #HashMap
  • #Interview
  • #소프트웨어개발
  • #정보처리기사
  • #소프트웨어설계
  • #dynamic_programming
  • #vue.js
전체 방문자
오늘
어제
전체
Copyright © 쭈미로운 생활 All rights reserved.
Designed by JJuum

티스토리툴바