[python]서울에서 김서방 찾기 [프로그래머스]

.·2020년 10월 11일
0

풀이 1.

Python

def solution(seoul):return '김서방은 {}에 있다'.format(seoul.index('Kim'))

풀이 2.

Python

def solution(seoul):return ('김서방은 %d에 있다' %seoul.index('Kim'))
profile
http://s6820w.tistory.com/ 로 블로그 이전

0개의 댓글