Skip to content

Instantly share code, notes, and snippets.

import hashlib
import random
from datetime import datetime
def select_subjects_for_today(subjects, num_select=2):
today_str = datetime.now().strftime("%Y-%m-%d")
hash_object = hashlib.md5(today_str.encode())
hash_hex = hash_object.hexdigest()