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 requests | |
| import json | |
| # from tqdm import tqdm | |
| filter_choice = { | |
| "1": "7ๅคฉๅ ๆฐๅข", | |
| "2": "30ๅคฉๅ ๆฐๅข", | |
| "3": "ๅๅนดๅ ๆฐๅข", | |
| } | |
| COOKIE = '' # ๆฟๆขไธบ่ชๅทฑ็ |
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
| class A(object): | |
| def test(self): | |
| print('from A') | |
| class B(A): | |
| def test(self): | |
| print('from B') | |
| class C(A): | |
| def test(self): |
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 functools import wraps | |
| def decorator1(func): | |
| print("start wrap1") | |
| @wraps(func) | |
| def wrapper(*args, **kwargs): | |
| print("in decorator1") | |
| result = func(*args, **kwargs) | |
| print("return decorator1") | |
| return 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
| func WriteGZ(path string, Inbytes []byte) []byte { | |
| buf := &bytes.Buffer{} | |
| gzWriter := gzip.NewWriter(buf) | |
| fiWriter := bufio.NewWriter(gzWriter) | |
| fiWriter.Write(Inbytes) | |
| fiWriter.Flush() | |
| gzWriter.Close() | |
| S3.put(outBytes) // useage | |
| } |
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
| /* | |
| This is an example of a golang gzip writer program, | |
| which appends data to a file. | |
| */ | |
| package main |
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
| Python 17h,18m โโโโโโโโโโโโโโโโโโโโโโ 85.83% | |
| JavaScript 32m โโโโโโโโโโโโโโโโโโโโโโ 02.69% | |
| JSON 27m โโโโโโโโโโโโโโโโโโโโโโ 02.30% | |
| SQL 26m โโโโโโโโโโโโโโโโโโโโโโ 02.16% | |
| YAML 20m โโโโโโโโโโโโโโโโโโโโโโ 01.69% |
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 psutil | |
| import os | |
| print( | |
| "ๅฝๅ่ฟ็จ็ๅ ๅญไฝฟ็จ๏ผ%.4f GB" | |
| % (psutil.Process(os.getpid()).memory_info().rss / 1024 / 1024 / 1024) | |
| ) |
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 ipdb import set_trace;set_trace(context=30) |
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
| <div class="main-ctr"> | |
| <svg xmlns="http://www.w3.org/2000/svg" width="540" height="620" viewBox="0 0 540 620"> | |
| <g id="Page-1" fill="none" fill-rule="evenodd"> | |
| <g id="modal-with-genie-effect"> | |
| <path id="step-3" stroke="#979797" d="M186 561.005c0-2.764 2.234-5.005 4.998-5.005h157.004c2.76 0 4.998 2.242 4.998 5.005v33.99c0 2.764-2.234 5.005-4.998 5.005H190.998c-2.76 0-4.998-2.242-4.998-5.005v-33.99z" opacity=".504" /> | |
| <path id="step-2" stroke="#979797" d="M270.136 122h237.356c2.758 0 4.36 2.15 3.577 4.8 0 0-23.333 86.246-92.842 174.822-69.51 88.575-66.458 185.37-66.458 185.37-.033 2.776-2.25 5.008-5.01 5.008H193.51c-2.76 0-4.977-2.232-5.01-5.008 0 0 3.05-96.795-66.458-185.37C52.534 213.046 29.202 126.8 29.202 126.8c-.783-2.65.82-4.8 3.578-4.8h237.356z" opacity=".5" /> | |
| <path id="step-0" stroke="#979797" d="M20 26.003C20 23.24 22.23 21 25.01 21h489.98c2.767 0 5.01 2.242 5.01 5.003v289.994c0 2.763-2.23 5.003-5.01 5.003H25.01c-2.767 0-5.01-2.242-5.01-5.003V26.003z" /> | |
| <pat |
NewerOlder