[Python] 해당 타입의 자료에 들어있는 메소드 알아내기
int면 int, string이면 string 같은 타입은 이미 내장되어 있는 메소드가 있다 그게 어떤 것들이 있는지 메소드의 리스트를 출력하는 방법이다. file=open("textfile.txt", 'r') print(type(file)) print(dir(file)) Out ['_CHUNK_SIZE', '__class__', '__del__', '__delattr__', '__dict__', '__dir__', '__doc__', '__enter__', '__eq__', '__exit__', '__format__', '__ge__', '__getattribute__', '__gt__', '__hash__', '__init__', '__init_subclass__', '__iter__', '__le_..