일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
Tags
- coding
- 코딩
- 파이썬
- mysql
- import re
- 데이터분석
- 코테
- python
- programmers
- 완전탐색
- Stack
- lambda
- time complexity
- join
- CodingTest
- coding test
- 프로그래머스
- 시간복잡도
- itertools
- Queue
- 조합
- 코딩테스트
- level4
- lv4
- counter
- Level2
- sql
- 연습문제
- collections
- BFS
- Today
- Total
목록np.where (1)
ror_coding
[Programmers] [카카오 인턴] 키패드 누르기 - 67256
키패드 위 해당 번호가 있는 index를 구하기 위해 np.where()을 사용! Question 순서대로 누를 번호가 담긴 배열 numbers, 왼손잡이인지 오른손잡이인 지를 나타내는 문자열 hand가 매개변수로 주어질 때, 각 번호를 누른 엄지손가락이 왼손인 지 오른손인 지를 나타내는 연속된 문자열 형태로 return 하도록 solution 함수를 완성해주세요. Code import numpy as npdef solution(numbers, hand): result = '' l, r = [3,0], [3,2] phone = [[1,2,3],[4,5,6],[7,8,9],['*',0,'#']] matrix = np.array(phone,dtype='object') # object를..
Algorithm/Python
2024. 10. 24. 13:41