1 2 3 4 5 6 7 8 9 10 11 12 | # # µû¶óÇÏ¸ç ¹è¿ì´Â ÆÄÀ̽ã°ú µ¥ÀÌÅÍ°úÇÐ(»ý´ÉÃâÆÇ»ç 2020) # 9.10 Á¤±Ô½ÄÀ» È°¿ëÇؼ ¸ÚÁö°Ô °Ë»öÀ» ÇÏÀÚ, 238ÂÊ # import re f = open('d:/data/UNDHR.txt') # ÇöÀç Æú´õ¿¡ ÀÖ´Â ÆÄÀÏÀ» Àоî¿Â´Ù. for line in f: line = line.rstrip() if re.search('^\([0-9]+\)', line) : print(line) | cs |