Rev 4158 | Go to most recent revision | Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
20 | reyssat | 1 | !if $wims_read_parm!=slib_header |
2 | !goto proc |
||
3 | !endif |
||
4 | slib_title=Cut out embedded choices for OEF |
||
5 | slib_parms=1\ |
||
6 | ,the input text (embedding delimiter: `??') |
||
7 | slib_author=Gang Xiao |
||
8 | slib_out=Text output with each choice in isolated lines |
||
9 | slib_comment=<b>This version is deprecated. Please use text/cutchoice2\ |
||
10 | for new applications.</b>\ |
||
11 | <p>For example, on the input text\ |
||
12 | <p><tt>The class has ??3,5,6,7?? pupils with average score of ??20,30,40??\ |
||
13 | </tt><p>\ |
||
14 | will be transformed to\ |
||
15 | <pre>\ |
||
16 | The class has\ |
||
17 | 3,5,6,7\ |
||
18 | pupils with average score of\ |
||
19 | 20,30,40\ |
||
20 | </pre>\ |
||
21 | The lines of even numbers may then be singled out for creating embedded\ |
||
22 | choices. |
||
23 | !exit |
||
24 | |||
25 | :proc |
||
26 | slib_out=!lines2words $wims_read_parm |
||
27 | slib_out=!replace internal ?? by $\ |
||
28 | $ in $slib_out |
||
29 | slib_out=!nonempty lines $slib_out |
||
30 | slib_out=!translate internal $\ |
||
31 | $ to ; in $slib_out |
||
32 | |||
33 |