์ด์ https://github.com/junhoyeo/standard-is ๋ ํฌ์์ ๊ด๋ฆฌ๋ฉ๋๋ค.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import numpy as np | |
| def check(x, y, z, log=False): | |
| s1 = True if any(i==3 for i in [x, y, z*2]) else False | |
| s2 = 3*(x+y+2*z)==x*y+2*y*z+2*z*x | |
| if log: print(3*(x+y+2*z), '==', x*y+2*y*z+2*z*x) | |
| return s1 and s2 | |
| for i in np.arange(0, 100, 0.5): | |
| for j in np.arange(0, 100, 0.5): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def check_valid(_id): # id='0000000000000' | |
| '''Validate Korean RRN via last number''' | |
| check = 0 | |
| for i in range(8): | |
| check += (i+2)*int(_id[i]) | |
| for i in range(8, 12): | |
| check += (i-6)*int(_id[i]) | |
| check = (11 - (check % 11)) % 10 | |
| if check == int(_id[12]): | |
| return True |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from pptx import Presentation | |
| from pptx.util import Inches | |
| prs = Presentation() | |
| prs.slide_width = 11887200 | |
| prs.slide_height = 6686550 | |
| title_slide_layout = prs.slide_layouts[0] | |
| for i in range(1, int(input()): | |
| slide = prs.slides.add_slide(title_slide_layout) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| users = [{'name': 'a11', 'type': 'a11234'}, {'name':'bbb', 'type':'ddd'},{'name':'ccc','type':'ddvfa1'}] | |
| [user for user in users if any(query in value for key, value in user.items())] | |
| [{'name': 'a11', 'type': 'a11234'}, {'name': 'ccc', 'type': 'ddvfa1'}] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #pragma once | |
| #ifndef _SAVE_SCORE_ | |
| #define _SAVE_SCORE_ | |
| #include <stdio.h> | |
| // score.txt์์ ํ์ฌ ์ ์๋ฅผ ๊ฐ์ ธ์จ๋ค. | |
| int load_score() { | |
| int score; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from pprint import pprint | |
| matrix = [[0] * 9 for _ in range(8)] | |
| for row in range(8): | |
| for col in range(9): | |
| matrix[row][col] = col + row * 9 | |
| pprint(matrix) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from itertools import combinations | |
| marbles = list(range(1, 11)) | |
| combs = list(combinations(marbles, 4)) | |
| result = 0 | |
| for comb in combs: | |
| if any(item % 3 == 0 for item in comb): | |
| result += 1 | |
| print(result) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {"status":"OFF","message":"."} |