Hackerrank 레벨업하기
문제
Designer PDF Viewer
def designerPdfViewer(h, word):
alpha = ['a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t','u','v','w','x','y','z']
count = len(word)
word = list(set(list(word)))
word_index = []
heights = []
for i in word:
word_index.append(alpha.index(i))
for i in word_index:
heights.append(h[i])
return count * max(heights)
궁금하신게 있다면 메일 주세요.
k2h7913@daum.net
cafehero123@gmail.com