mirror of
https://github.com/prdlk/leetcode.git
synced 2026-09-17 07:26:27 +00:00
README restructure + drills only from learned topics
This commit is contained in:
+9
-3
@@ -166,9 +166,12 @@ export async function dueReviews(db: D1Database, date: string): Promise<ProblemR
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Blind drills: unsolved optional problems from topics taught in EARLIER
|
* Blind drills: unsolved optional problems from topics ALREADY LEARNED —
|
||||||
* weeks (the current week's optional pool is reserved for Saturday's gate),
|
* scheduled in an earlier week (the current week's optional pool is reserved
|
||||||
* never repeated, seeded by date. Boosted topics contribute up to 2 extra.
|
* for Saturday's gate) AND showing learning evidence: at least one of the
|
||||||
|
* topic's core problems has entered the ladder. A skipped learning day never
|
||||||
|
* feeds drills just because its calendar week lapsed. Never repeated,
|
||||||
|
* seeded by date. Boosted topics contribute up to 2 extra.
|
||||||
*/
|
*/
|
||||||
export async function pickDrills(
|
export async function pickDrills(
|
||||||
db: D1Database,
|
db: D1Database,
|
||||||
@@ -184,6 +187,9 @@ export async function pickDrills(
|
|||||||
WHERE p.set_label = 'optional' AND p.stage = 'new'
|
WHERE p.set_label = 'optional' AND p.stage = 'new'
|
||||||
AND p.lc_number NOT IN (SELECT lc_number FROM drill_pool_used)
|
AND p.lc_number NOT IN (SELECT lc_number FROM drill_pool_used)
|
||||||
AND NOT EXISTS (SELECT 1 FROM attempts a WHERE a.lc_number = p.lc_number)
|
AND NOT EXISTS (SELECT 1 FROM attempts a WHERE a.lc_number = p.lc_number)
|
||||||
|
AND EXISTS (SELECT 1 FROM problems c
|
||||||
|
WHERE c.topic_issue = p.topic_issue
|
||||||
|
AND c.set_label = 'core' AND c.stage != 'new')
|
||||||
ORDER BY p.lc_number`,
|
ORDER BY p.lc_number`,
|
||||||
)
|
)
|
||||||
.all<ProblemRow & { boost: number }>();
|
.all<ProblemRow & { boost: number }>();
|
||||||
|
|||||||
Reference in New Issue
Block a user