Notice
Recent Posts
Recent Comments
Link
250x250
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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
- codingtest
- 파이썬
- AndroidStudio
- 백준
- Vue
- Algorithm
- 안드로이드
- cos pro
- 분할정복
- 코드품앗이
- django
- C++
- 코테
- BAEKJOON
- cos pro 1급
- vuejs
- 동적계획법
- Python
- 안드로이드스튜디오
- DFS
- 알고리즘
- issue
- DFS와BFS
- 코딩테스트
- 개발
- 동적계획법과최단거리역추적
- Flutter
- cos
- DART
- android
Archives
- Today
- Total
목록로봇을 움직여주세요 python (1)
Development Artist
![](http://i1.daumcdn.net/thumb/C150x150/?fname=https://blog.kakaocdn.net/dn/DGVhT/btrueyOtPkR/VbHozq8XYppIJ7vBr5DlAk/img.png)
문제 유형 코딩 난이도 easy Note Nothing Code # -*- coding: utf-8 -*- # UTF-8 encoding when using korean # 2차 6번 def solution(commands): answer = [] x = 0 y = 0 list_commands = list(commands) for i in list_commands: if i == 'L': x -= 1 elif i == 'R': x += 1 elif i == 'U': y += 1 else: y -= 1 answer.append(x) answer.append(y) return answer commands = "URDDL" ret = solution(commands) print("solution 함수의 반환 ..
Algorithm/COS
2022. 2. 25. 10:21