일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
- 머신러닝
- 파이썬
- Python
- r
- 이것이 코딩테스트다
- 데이터분석
- Google ML Bootcamp
- tableau
- SQL
- 자격증
- 딥러닝
- 태블로
- 시각화
- pytorch
- ML
- 데이터 분석
- matplotlib
- Deep Learning Specialization
- scikit learn
- 코딩테스트
- IRIS
- 통계
- 데이터분석준전문가
- ADsP
- SQLD
- pandas
- 회귀분석
- sklearn
- 이코테
- 데이터 전처리
- Today
- Total
목록코딩 테스트 (10)
함께하는 데이터 분석

음료수 얼려 먹기 n, m = map(int, input().split()) graph = [] for i in range(n) : graph.append(list(map(int, input()))) def dfs(x, y) : if x = n or y = m : return False if graph[x][y] == 0 : graph[x][y] = 1 dfs(x - 1, y) dfs(x + 1, y) dfs(x, y - 1) dfs(x, y + 1) return True return False result = 0 for i in range(n) : for j in range(m) : if dfs(i, j) == True : result += 1 print(result..

최댓값과 최솟값 def solution(s): answer = list(map(int,s.split())) return str(min(answer)) + ' ' + str(max(answer)) JadenCase 문자열 만들기 def solution(s): answer = list(map(str, s.split(' '))) for i in range(len(answer)) : answer[i] = answer[i].capitalize() return ' '.join(answer) 최솟값 만들기 def solution(A, B) : A.sort() B.sort(reverse = True) summ = 0 for i in range(len(A)) : summ += A[i] * B[i] return summ ..

소수 판별(에라토스테네스의 체) import math n = 1000 array = [True for i in range(n + 1)] array[1] = 0 for i in range(1, int(math.sqrt(n)) + 1) : if array[i] == True : j = 2 while i * j 0 : num, mod = divmod(num, n) rev_base += str(mod) return rev_base[::-1] 1에서 n까지 각 수의 약수의 개수 import math n = 15 arr = [] for i in range(1, n + 1) : count = 0 for j in range(1, int(math.sqrt(i)) + 1) : if j * j == i : count += ..

부품 찾기 # 부품 찾기 (시간 초과할 수도) N = int(input()) arr = list(map(int, input().split())) M = int(input()) data = list(map(int, input().split())) for i in range(len(data)) : if data[i] in arr : print('yes', end = ' ') else : print('no', end = ' ') # 부품 찾기(이진 탐색) def binary_search(array, target, start, end) : while start target : # 중간점보다 target이 작으므로 왼쪽 end = mid - 1 else : # 중간점보다 target이 크므로 오른쪽 start =..

위에서 아래로 N = int(input()) arr = [] for i in range(N) : arr.append(int(input())) arr = sorted(arr, reverse = True) for j in arr : print(j, end = ' ') 성적이 낮은 순서로 학생 출력하기 N = int(input()) arr = [] for _ in range(N) : data = input().split() arr.append((data[0], int(data[1]))) arr = sorted(arr, key = lambda x : x[1]) for student in arr : print(student[0], end = ' ') 두 배열의 원소 교체 N, K = map(int, input()..

상하좌우 N = int(input()) x, y = 1, 1 data = list(map(str, input().split())) dx = [0, 0, -1, 1] dy = [-1, 1, 0, 0] move = ['L', 'R', 'U', 'D'] for i in data : for j in range(len(move)) : if i == move[j] : nx = x + dx[j] ny = y + dy[j] if nx N or ny > N : continue x, y = nx, ny print(x, y) 시각 N = int(input()) count = 0 for i in range(N + 1) : for j in range(60) : for k in range(..

거스름돈 n = int(input()) arr = [500, 100, 50, 10] count = 0 for i in arr : count += n // i n %= i print(count) 큰 수의 법칙 N, M, K = map(int, input().split()) data = list(map(int, input().split())) data.sort() summ = 0 i = 1 while i

나머지가 1이 되는 수 찾기 def solution(n): answer = [] for i in range(1, n + 1) : if n % i == 1 : answer.append(i) return answer[0] def solution(n) : return [x for x in range(1, n + 1) if n % x == 1][0] 평균 구하기 def solution(arr): answer = sum(arr)/len(arr) return answer def solution(arr) : return sum(arr) / len(arr) 짝수와 홀수 def solution(num): if num % 2 == 0 : return "Even" else : return "Odd" def solution(..

6052 print('True' if int(input()) else 'False') 6053 print('True' if not int(input()) else 'False') 6054 a, b = map(int, input().split()) print('True' if a and b else 'False') 6055 a, b = map(int, input().split()) print('True' if a or b else 'False') 6056 a, b = map(int, input().split()) print('True' if (a and not b) or (not a and b) else 'False') 6057 a, b = map(int, input().split()) print('Tru..

6001 print("Hello") 6002 print("Hello World") 6003 print("Hello\nWorld") 6004 print("'Hello'") 6005 print('"Hello World"') 6006 print("\"!@#$%^&*()'") 6007 print("\"C:\\Download\\'hello'.py\"") 6008 print('print("Hello\\nWorld")') 6009 print(input()) 6010 print(int(input())) 6011 print(float(input())) 6012 print(input() + "\n" + input()) 6013 a = input() b = input() print(b + "\n" + a) 6014 prin..