본문 바로가기

Problem-solving119

프로그래머스 - (2019 KAKAO BLIND RECRUITMENT) 후보키 (Python3) https://programmers.co.kr/learn/courses/30/lessons/42890 코딩테스트 연습 - 후보키 [["100","ryan","music","2"],["200","apeach","math","2"],["300","tube","computer","3"],["400","con","computer","4"],["500","muzi","music","3"],["600","apeach","music","2"]] 2 programmers.co.kr import itertools """ KAKAO Level2 후보키 """ attribute_list = [] candidate_key_count = 0 # 한 attribute에 해당하는 모든 value들을 검사하여 # 해당 attribu.. 2020. 5. 31.
프로그래머스 - (2019 KAKAO BLIND RECRUITMENT) 오픈채팅방 (Python3) https://programmers.co.kr/learn/courses/30/lessons/42888 코딩테스트 연습 - 오픈채팅방 오픈채팅방 카카오톡 오픈채팅방에서는 친구가 아닌 사람들과 대화를 할 수 있는데, 본래 닉네임이 아닌 가상의 닉네임을 사용하여 채팅방에 들어갈 수 있다. 신입사원인 김크루는 카카오톡 오 programmers.co.kr """ 2019 KAKAO BLIND RECRUITMENT 오픈채팅방 """ def solution(record): answer = [] all_user_id_and_nickname = {} all_user_id_and_message_in_hangul_in_chatting_room = [] for record_line in record: split_record_.. 2020. 5. 30.
백준 - 바이러스(2606번) (Python3) https://www.acmicpc.net/problem/2606 2606번: 바이러스 첫째 줄에는 컴퓨터의 수가 주어진다. 컴퓨터의 수는 100 이하이고 각 컴퓨터에는 1번 부터 차례대로 번호가 매겨진다. 둘째 줄에는 네트워크 상에서 직접 연결되어 있는 컴퓨터 쌍의 수가 주어�� www.acmicpc.net """ 2606번 바이러스 """ def dfs(current_checking_computer_number): global total_infected_computer_count # 만약 이미 방문한 컴퓨터라면 if is_visited_computer[current_checking_computer_number]: return # 새로 방문한 컴퓨터 이므로, 방문했음을 표시 is_visited_comp.. 2020. 5. 28.
백준 - 보물(1026번) (Python3) https://www.acmicpc.net/problem/1026 1026번: 보물 첫째 줄에 N이 주어진다. 둘째 줄에는 A에 있는 N개의 수가 순서대로 주어지고, 셋째 줄에는 B에 있는 수가 순서대로 주어진다. N은 50보다 작거나 같은 자연수이고, A와 B의 각 원소는 100보다 작거� www.acmicpc.net # 1 2020. 5. 26.