Generate cross sum puzzles
generate_cross_sumsUse this when the user wants printable cross-sum puzzles (cross sums, number crossword puzzles with sums, addition logic puzzles) as a PDF with an answer key, or wants to solve one on screen. Each grid from 6 x 6 to 12 x 12 (counting the clue row and column) has white squares for the digits 1 to 9 and clue squares with sums; each run of white squares adds up to its clue with no repeated digit. Put one object per puzzle in puzzles[] when they differ (size, difficulty, seed); for a set of the same kind, set count with size and difficulty. A solver checks each puzzle for one solution. The PDF has 1, 2 or 4 puzzles per page on Letter or A4, an optional title and name line, and answer pages; the card lets the user fill in digits and check them. Defaults: 1 medium 8 x 8 puzzle, Letter, 1 per page, name line and answer key on. Does not solve a puzzle from a photo or make grids larger than 12 x 12.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| seed | No | Starting seed; puzzle N uses seed + N - 1. Reuse it to reprint the same puzzles. Example: 2026 | |
| size | No | Grid size for all puzzles, 6 to 12 (default 8), counting the clue row and column. Example: 10 | |
| count | No | How many puzzles when they are all the same kind (1 to 12, default 1). Example: 4 | |
| paper | No | letter (default, US 8.5 x 11 in) or a4. Example: a4 | |
| title | No | Title printed at the top of each page. Example: Weekend Cross Sums | |
| puzzles | No | One object per puzzle when the puzzles differ, e.g. [{"size":6,"difficulty":"easy"},{"size":10,"difficulty":"hard"}]. Leave out and use count for a set of the same kind. Up to 12. | |
| per_page | No | Puzzles per printed page: 1 (default), 2 or 4. Example: 2 | |
| name_line | No | Print a Name and Date line on the puzzle pages (default true). Example: false | |
| answer_key | No | Add answer pages with the solved grids (default true). Example: true | |
| difficulty | No | Difficulty for all puzzles: easy, medium (default) or hard. Example: easy |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| count | Yes | ||
| notes | Yes | ||
| pages | Yes | ||
| paper | Yes | ||
| title | Yes | ||
| puzzles | Yes | ||
| per_page | Yes | ||
| downloads | Yes | ||
| name_line | Yes | ||
| answer_key | Yes | ||
| puzzle_count | No | ||
| all_one_solution | Yes |