Python

· Python
리스트 슬라이싱>>> mylist = ['a', 'b', 'c', 'd', 'e', 'f', 'g']mylist[0:2] // ['a', 'b',] -> 0부터 2개mylist[:3] // 처음부터 3개mylist[2:] // ['c', 'd', 'e', 'f', 'g'] -> index 2부터 끝까지mylist[3:-1] // ['d', 'e', 'f'] // 3부터 끝에서부터 하나 온 index까지 리스트 추가mylist.append('h') 리스트 특정 위치에 추가 mylist.insert(3, 'k') 삭제del mylist[-1] // 끝에서부터 하나 제거
· Python
Python용 Excel 외부 라이브러리이 xlsxWriter를 Eclipse plugin인 PyDev 모듈에서 사용하기 위한 절차를 설명한다. pip 설치 https://pip.pypa.io/en/latest/installing.htmlpython get-pip.py를 다운로드 받고cd c:\Python27python get-pip.py XlsxWriter설치http://xlsxwriter.readthedocs.org/getting_started.html cd Scriptspip2.7 install XlsxWriter 여기까지 하면 C:\Python27\Lib\site-packages\xlsxwriter 에 모듈이 설치된다. 이제 이클립스를 실행하고https://www.ics.uci.edu/~patti..
CodePoetry
'Python' 카테고리의 글 목록 (3 Page)