Description Usage Arguments Details
A 'puzzle string' is a compact text representation of a nonogram puzzle, whereas a 'puzzle' is an R list object representing the puzzle.
1 2 3 | convert_puzzle_string_to_puzzle(puzzle_string)
convert_puzzle_to_puzzle_string(puzzle)
|
puzzle_string |
compact string representation of a puzzle |
puzzle |
R list representation of a puzzle |
A puzzle
is a list containing:
a list of the row clues
a list of the column clues
A clue
is a list of integers which is the run-length encoding of just
the filled spaces in the final puzzle.
e.g.
list(row_clues = list(2L, 2:1, c(1L, 1L), 3L, c(1L, 1L), c(1L, 1L), 2L, c(1L, 1L), 1:2, 2L),
col_clues = list(2:1, c(2L, 1L, 3L), 7L, c(1L, 3L), 2:1))
A puzzle string
is a just a compact string representation of the puzzle.
It consists of:
the numbers for each clue separated by a comma
each clue separated by a colon
the row and column clues (in that order) separated by a dash
e.g. "2:2,1:1,1:3:1,1:1,1:2:1,1:1,2:2-2,1:2,1,3:7:1,3:2,1"
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.