Search

코테 실전 문제

def solution(history, keyword, option = [["W","F"]]): answer = [] if option[0][1] == 'F': answer.append("empty") else: for i in range(len(history)): if history[i].count(keyword) >= 1: answer.append(history[i]) else : answer.append("empty") return answer solution(["hello i am david", "hello kail", "hi tina"], [['W','T']],"hello")
SQL
복사