-USING: help.markup help.syntax kernel math math.order sequences ;
-IN: math.combinatorics
+USING: help.markup help.syntax kernel math math.combinatorics
+math.combinatorics.private math.order sequences ;
 
 HELP: factorial
 { $values { "n" "a non-negative integer" } { "n!" integer } }

        "{ { 1 1 } { 1 2 } { 2 1 } { 2 2 } }"
    }
} ;
PRIVATE>

{ $values { "seq" sequence } { "k" "a non-negative integer" } { "quot" { $quotation ( ... elt -- ... ) } } }
{ $description "Applies the quotation to each combination of " { $snippet "seq" } " choosing " { $snippet "k" } " elements, in order." } ;

HELP: factoradic
{ $values { "n" integer } { "factoradic" sequence } }
{ $description "Converts a positive integer " { $snippet "n" } " to factoradic form. The factoradic of an integer is its representation based on a mixed radix numerical system that corresponds to the values of " { $snippet "n" } " factorial." }
