# Process
# 1. Input numbers (int)
# 2. Convert int to str
# 3. Sort using value multiplied by 4, Descending direction.
# 4. Handle exception case
# 5. Return
def solution(numbers):
result = ''
array_string = []
for number in numbers:
array_string.append(str(number))
array_string = quicksort(array_string)
for string in array_string:
result += string
if result.startswith('0'):
result = '0'
return result
def quicksort(x):
if len(x) <= 1:
return x
pivot = x[len(x) // 2]
less = []
more = []
equal = []
for a in x:
if a*4 > pivot*4:
less.append(a)
elif a*4 < pivot*4:
more.append(a)
else:
equal.append(a)
return quicksort(less) + equal + quicksort(more)
스택/큐 04 - 기능개발, 프로그래머스, 알고리즘, Programmers, Stack, Queue, Hash, 코딩테스트, Algorithm, 풀
# Process # 1. Input priorities, location # 2. Make location_tracker plate for the location index I need to know # 3. Iterate while remaining priorities # 3.1. Pop first..
itdar.tistory.com
아나콘다 환경 설치, 복사, 파이썬, Anaconda enviroment export/import, How to transfer conda environment, Python, 복
How to clone and make new conda enviroment on somewhere. 아나콘다의 파이썬 및 각종 개발환경 설치한 것을 동일 PC 혹은 다른 PC로 옮길 때 사용하는 커맨드라인 1. Check env name what you wanna export or..
itdar.tistory.com
2020/10/07 - [Life/Item review] - Lenovo 레노보 씽크패드 Thinkpad 빨콩 무선키보드/블루투스/울트라나브2/트랙키보드 구매 후기
Lenovo 레노보 씽크패드 Thinkpad 빨콩 무선키보드/블루투스/울트라나브2/트랙키보드 구매 후기
빨콩 + 키감 + 무선 울트라나브2 를 기다리다가 최근 나왔길래 고민안하고 샀다. -> 가격 13만 5천원 내외였던 것 같은데 음.. 가성비는 그닥 -> 빨콩 예전 x1 이후에 간만에 빨콩을 쓰니 손이 잘 안
itdar.tistory.com
CodeSignal Intro Databases #1 ProjectList. Algorithm,알고리즘,LeetCode,Codefights,CodeSignal,코드파이트,코드시그널
CodeSignal Intro Databases #1 ProjectList. Algorithm,알고리즘,LeetCode,Codefights,CodeSignal,코드파이트,코드시그널,예제,그래프,Graph,example,c++,java,재귀,recursive,datastructure,techinterview,codin..
itdar.tistory.com