-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnew_problem.bat
More file actions
29 lines (27 loc) · 1.25 KB
/
new_problem.bat
File metadata and controls
29 lines (27 loc) · 1.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
@echo off
setlocal EnableExtensions
REM ============================================
REM Create New Problem (pass-through wrapper)
REM All logic lives in src/codegen
REM
REM Usage:
REM new_problem.bat 1 Generate solution skeleton
REM new_problem.bat 1 --with-tests Also generate test files
REM new_problem.bat 1 --solve-mode infer Auto-generate solve()
REM new_problem.bat 1 --solve-mode tiered Use tiered codec generation
REM new_problem.bat 1 --codec-mode import Use import mode (default)
REM new_problem.bat 1 --codec-mode inline Embed codec inline
REM new_problem.bat 1 --dry-run Preview without writing
REM
REM Tiered Problem Generation:
REM Tier-1/1.5 problems auto-detect and use tiered mode.
REM No need to specify --solve-mode for ListNode/TreeNode problems.
REM
REM Examples:
REM new_problem.bat 15 3Sum (Tier-0)
REM new_problem.bat 104 Max Depth of Binary Tree (Tier-1, auto-tiered)
REM new_problem.bat 142 Linked List Cycle II (Tier-1.5, auto-tiered)
REM new_problem.bat 15 --with-tests 3Sum with example tests
REM ============================================
python -m codegen new %*
exit /b %ERRORLEVEL%