- https://alexharri.com/blog/jsdoc-as-an-alternative-typescript-syntax
- https://dev.to/samuel-braun/boost-your-javascript-with-jsdoc-typing-3hb3
Here's how you can do it for common primitive types:
Here's how you can do it for common primitive types:
import socket | |
import threading | |
import select | |
SOCKS_VERSION = 5 | |
class Proxy: |
import logging | |
from colorama import init, Fore, Back | |
init(autoreset=True) | |
class ColorFormatter(logging.Formatter): | |
# Change this dictionary to suit your coloring needs! | |
COLORS = { | |
"WARNING": Fore.RED, |
## Link to excel export of market watch | |
http://members.tsetmc.com/tsev2/excel/MarketWatchPlus.aspx?d=0&format=0 | |
## Variables list | |
inscode: "15521712617204216" | |
iid: "IRO1SFKZ0001" | |
l18: "سفارس" | |
l30: "سيمان فارس و خوزستان" | |
py: "8557" | |
bvol: "5131363" |
import socket | |
UDP_IP = "127.0.0.1" | |
UDP_PORT = 1234 | |
MESSAGE = "Hello, World!" | |
print ("UDP target IP:", UDP_IP) | |
print ("UDP target port:", UDP_PORT) | |
print ("message:", MESSAGE) |
import json | |
import wikitextparser | |
with open("table1.json") as f: # or table2.json | |
data = json.load(f) | |
source = data["source_text"] | |
parsed = wikitextparser.parse(source) | |
print("Processing tables") | |
# This one will hang |
# aproducer.py | |
# | |
# Async Producer-consumer problem. | |
# Challenge: How to implement the same functionality, but no threads. | |
import time | |
from collections import deque | |
import heapq | |
class Scheduler: |