편집 기록

편집 기록
  • 프로필 정영훈님의 편집
    날짜2018.05.21

    리스트를 집합으로 변환하고 싶어요


    list2007 = []
    
    for i in range(len(res2007)):
    
        a = res2007[i][0]
        list2007.append(a)
    
    set2007 = set([list2007])
    

    TypeError Traceback (most recent call last)

    in ()

    ----> 1 set2007 = set([list2007])

    TypeError: 'tuple' object is not callable

    참고로 res2007도 리스트타입 입니다.

  • 프로필 김한나님의 편집
    날짜2018.05.21

    리스트를 집합으로 변환하고 싶어요


    list2007 = []

    for i in range(len(res2007)):

    a = res2007[i][0]
    list2007.append(a)
    

    set2007 = set([list2007])


    TypeError Traceback (most recent call last)

    in ()

    ----> 1 set2007 = set([list2007])

    TypeError: 'tuple' object is not callable

    참고로 res2007도 리스트타입 입니다.