Algorithm Notebook 2 — Sorting Stu Records: Three Eras of C++

Luogu P1093 — Scholarship link: https://www.luogu.com.cn/problem/P1093 1. Problem Statement There are $n$ Stus, each with three exam scores: Chinese (ch), Math (math), and English (eng). The task is to rank them by the following criteria: Total score — descending (higher is better); Chinese score — descending …...
July 12, 2026 · 10 min · Xia Liao

Algorithm Notebook 1 — High-Precision Arithmetic & Quick Sort

Luogu P1045 — Mersenne Numbers link: https://www.luogu.com.cn/problem/P1045 1. Problem Statement A Mersenne number is an integer of the form $2^P - 1$ where $P$ is prime. Given $P$ ($1000 \lt P \lt 3,100,000$), the task is to compute: The number of decimal digits of $2^P - 1$; The last $500$ decimal digits of...
July 8, 2026 · 17 min · Xia Liao