๐ฏ
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
package main | |
import ( | |
"bytes" | |
"context" | |
"encoding/json/jsontext" | |
v2 "encoding/json/v2" | |
"fmt" | |
"log" | |
"net" |
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 asyncio | |
import json | |
import os | |
import time | |
from collections import OrderedDict | |
from dataclasses import dataclass | |
from typing import Any | |
import aiofiles |
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 asyncio | |
import json | |
from datetime import datetime | |
from typing import Any | |
import aio_pika | |
from aio_pika.abc import AbstractChannel, AbstractQueue, AbstractRobustConnection | |
RABBITMQ_URL = "amqp://<USER>:<PASSWORD>@localhost:5672/<VHOST>" | |
QUEUE_NAME = "demo.queue" |
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 { useTheme } from "./theme"; | |
function App() { | |
const { isDark, toggleTheme } = useTheme(); | |
return ( | |
<div | |
id="top" | |
className="min-h-screen bg-white text-gray-900 dark:bg-gray-950 dark:text-gray-100" | |
> |
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 decimal import Decimal | |
from textual.app import App, ComposeResult | |
from textual.containers import Container | |
from textual.reactive import var | |
from textual.widgets import Button, Digits | |
""" | |
* Import Description | |
- App: ์ ํ๋ฆฌ์ผ์ด์ ์ ๊ธฐ๋ณธ ํด๋์ค |
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 recursive_tower_of_hanoi(n, source="A", auxiliary="B", destination="C"): | |
""" | |
์ฌ๊ท ํธ์ถ์ ์ด์ฉํด ํ๋ ธ์ด์ ํ ๋ฌธ์ ๋ฅผ ํด๊ฒฐํฉ๋๋ค. | |
๋งค๊ฐ๋ณ์: | |
n (int): ๋์คํฌ ๊ฐ์ (0 ์ด์์ ์ ์์ฌ์ผ ํจ) | |
source (str): ์์ ๊ธฐ๋ฅ ์ด๋ฆ | |
auxiliary (str): ๋ณด์กฐ ๊ธฐ๋ฅ ์ด๋ฆ | |
destination (str): ๋ชฉ์ ์ง ๊ธฐ๋ฅ ์ด๋ฆ |
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 recursive_solve(maze, x, y, end_x, end_y): | |
# ๋ฏธ๋ก ํฌ๊ธฐ | |
rows = len(maze) | |
cols = len(maze[0]) | |
# ๊ธฐ์ ์กฐ๊ฑด: ๋ชฉํ ์ง์ ์ ๋๋ฌ | |
if x == end_x and y == end_y: | |
maze[x][y] = 2 # ๊ฒฝ๋ก ํ์ | |
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
""" | |
Counting Sort Algorithm Implementation | |
๊ณ์ ์ ๋ ฌ: ๊ฐ ์์์ ๊ฐ์๋ฅผ ์ธ์ด ์ ๋ ฌํ๋ ์๊ณ ๋ฆฌ์ฆ | |
์๊ฐ ๋ณต์ก๋: O(n + k) where k is the range of input | |
๊ณต๊ฐ ๋ณต์ก๋: O(k) | |
""" | |
import random | |
import time |
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
#!/usr/bin/env python3 | |
""" | |
Self-contained HTTP/1.1 server using only Python standard library. | |
Listens on port 8080, parses requests manually, routes GET/POST requests, | |
and logs raw TCP stream to stdout. | |
""" | |
import datetime | |
import socket | |
import sys |
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
# requirements: | |
# pip install Jinja2 secure-smtplib | |
import os | |
import smtplib | |
from email.mime.multipart import MIMEMultipart | |
from email.mime.text import MIMEText | |
from pathlib import Path | |
from jinja2 import Environment, FileSystemLoader |
NewerOlder