Changeset 30125 in project


Ignore:
Timestamp:
11/27/13 08:41:14 (6 years ago)
Author:
Ivan Raikov
Message:

suffix-tree: added more examples

Location:
release/4/suffix-tree/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • release/4/suffix-tree/trunk/suffix-tree.scm

    r27931 r30125  
    2424          suffix-tree-partition suffix-tree-merge
    2525          suffix-tree-branches suffix-tree-compfn suffix-tree-keyfn
    26           suffix-tree-branch-label suffix-tree-branch-children suffix-tree-branch-eol )
     26          suffix-tree-branch-label suffix-tree-branch-children
     27          suffix-tree-branch-eol )
    2728
    2829        (import scheme chicken)
  • release/4/suffix-tree/trunk/tests/run.scm

    r25777 r30125  
    1414(assert (equal? 'test2 (suffix-tree-lookup "2" t3)))
    1515
     16(define t4 (suffix-tree-insert "to" 'to t))
     17(define t5 (suffix-tree-insert "this" 'this t4))
     18(define t6 (suffix-tree-insert "the" 'the t5))
     19(define t7 (suffix-tree-insert "that" 'that t6))
     20
     21(define t8 (suffix-tree-lookup/partial  "th" t7))
     22(print (suffix-tree-lookup/partial  "e" t8))
     23(print (suffix-tree-lookup/partial  "that" t7))
Note: See TracChangeset for help on using the changeset viewer.