!set title=Word stress patterns Tonic
!if $wims_read_parm!=$empty
 !goto $wims_read_parm
!endif
oef2wims_version=3.22
author=Csilla Ducrocq
email=csilla.ducrocq@u-psud.fr
language=fr
computeanswer=no

ansorder=r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r
varcnt=104
prevarcnt=103
postvarcnt=0
replycnt=40
choicecnt=0
conditioncnt=0
feedbackcnt=0
format=html

val1=$imagedir
val2=$confparm1
val3=$confparm2
val4=$confparm3
val5=$confparm4

!if $testcondition=yes
 !goto test
!endif
!if $status=waiting
 !exit
!endif

val6=word_stress_patterns_tonic
!readproc slib/utilities/notepad Notepad,small 
tmp0=$slib_out
val7=$(tmp0)
tmp0=!nosubst Listen to the word and click on the stressed syllable.

val8=$(tmp0)
tmp0=!nosubst 

val9=$(tmp0)
val10=
val11=
val12=no
val13=no
val14=no
val15=no
val16=yes
val17=
val18=split
val19=1
val20=aucune de ces possibilités
val21=clickfill
val22=
val23=
val24=
val25=
val26=
val27=background-color: #99CCFF; margin: 2% 5%; padding: 2%;
val28=background-color: #FFCC99; color: black; margin: 2% 5%; padding: 2%;
val29=
val30=ol li {list-style: upper-alpha; }
val31=yes
val32=inside
val33=yes
val34=1
val35=
val36=
val37=
val38=---
tmp=!nonempty items $val6

tmp0=!randitem $tmp
val39=$(tmp0)
tmp0=!recordcnt $val39

val40=$[rint($(tmp0))]
val41=3
val42=1
val43=3

!ifval $val21 iswordof case 
val44= autocomplete=off
!endif
tmp0=!replace internal - by in $val38

val38=$(tmp0)
val45=$val22,$val23,$val24

!ifval $val25 = 
val25=++>
!endif

!ifval $val34 notwordof 0 
val34=$[rint( 1)]
!endif

!ifval $val26!=yes 
val46= noreaccent
!else
val46=
!endif

!ifval $val31 issametext no 
!readproc slib/utilities/nopaste  
tmp0=$slib_out
val47= $(tmp0)
!endif

!ifval $val8 issametext 
tmp0=!getdef instruction in $val39

val8= $(tmp0)
!endif

!ifval $val9 issametext 
tmp0=!getdef instruction2 in $val39

val9= $(tmp0)
!endif

!ifval $val17 issametext 
tmp0=!getdef size in $val39

val17= $(tmp0)
!endif

!ifval $val13 issametext 
tmp0=!getdef reading_file in $val39

val13= $(tmp0)
!endif
tmp0=!record 0 of $val13

val48=$(tmp0)

!ifval $val12 issametext 
tmp0=!getdef audio_file in $val39

val12= $(tmp0)
!endif

!ifval $val12 notsametext  and  $val12 notsametext no
!readproc slib/media/audio $val1/$val12,player=$val38 
tmp0=$slib_out
val49= 	<p align="center">$(tmp0)</p>
!endif

!ifval $val14 issametext 
tmp0=!getdef image_file in $val39

val14= $(tmp0)
!endif

!ifval $val14 notsametext  and  $val14 notsametext no
tmp0=!makelist <img src=$val1/x> for x in $val14

val50= 	$(tmp0)
!endif

!ifval $val15 issametext 
tmp0=!getdef video_file in $val39

val15= $(tmp0)
!endif
!if $val15 notsametext  and  $val15 notsametext no 

!ifval http notin $val15 
val15= $val1/$val15
!endif

!ifval $val15 notsametext 
val51= <a wims_target=external href="$val15">[video] </a></p>
!endif
!endif

!ifval $val10 issametext 
tmp0=!getdef choice in $val39

val52= $(tmp0)
!else
val52=$val10
!endif
val53=<style type="text/css">	 .question {$val27}	 .reponse {$val28}	 .oefstatement{$val29}	 $val30	 </style>	 

!ifval $val36 notwordof 1 2 3 4 5 6 7 8 9 10 
val36= 1
!endif

!ifval $val21 iswordof dragfill clickfill 
val17= $val17 x 1
!endif
val42=$[rint(min($val40,$val42))]
val41=$[rint(min($val42*$val41,$val40))]

!ifval $val16 issametext yes 
tmp0=!shuffle $val40

val54= $(tmp0) 
!else
tmp1=!makelist x for x = 1 to $val40

val54=	$(tmp1)
!endif
val55=
val56=
val57=
val58=
val59=
val60=0
val61=0
!for val62 = 1 to $val41 
tmp0=!record $(val54[$val62]) of $val39

tmp=!trim $(tmp0)
val63=!translate internal $	\
$ to ;; in $tmp
tmp=!translate internal $	$ to ; in $val63

tmp0=!rowcnt $tmp
val64=$[rint($(tmp0))]
t_=!replace internal \( by ( in ceil($val64/3)
tmp0=!exec pari $t_

val64=$[rint($(tmp0))]
tmp0=!shuffle $val64

val65=$(tmp0)
!for val66  = 1 to $val64 
val67=$[rint(-3+3*$(val65[$val66]))]
val68=$(val63[1+$val67;])
tmp=!trim $val55	      $(val63[2+$val67;])
val55=!translate internal $	\
$ to ;; in $tmp
tmp0=!replace internal / by  in $val68

tmp1=!nospace $(tmp0)

val69=$(tmp1)
tmp=!trim $val56	     $val69
val56=!translate internal $	\
$ to ;; in $tmp
tmp0=!replace internal / by ,  in $val68

tmp1=!nonempty items $(tmp0)

val70=$(tmp1)
tmp=!trim $val57	      $val70
val57=!translate internal $	\
$ to ;; in $tmp
tmp0=!itemcnt $val70

val59=$val59, $(tmp0)
!if $val12 issametext no 
val71=$(val63[3+$val67;])

!ifval $val71 issametext 
tmp0=!deaccent $val69

val71= $(tmp0).mp3
!endif
!readproc slib/media/audio $val1/$val71 
tmp0=$slib_out
val58=$val58,$(tmp0)
!endif
!next
val61=$[rint($val61 + $val64)]
val60=$val60,$val61
!next
tmp0=!itemcnt $val60

val72=$[rint($(tmp0)-1)]
tmp=!translate internal $	$ to ; in $val55

tmp0=!rowcnt $tmp
val73=$(tmp0)
tmp0=!nonempty items $val59

val59=$(tmp0)
tmp0=!nonempty items $val58

val58=$(tmp0)
tmp0=!makelist r x for x=1 to $val73

val74=$(tmp0)
tmp=!trim 
val75=!translate internal $	\
$ to ;; in $tmp
tmp=!trim 
val76=!translate internal $	\
$ to ;; in $tmp
val77=$[rint(1)]
val78=$[rint($(val60[1]))]
!while  $val78 notsametext  
tmp0=!makelist r x for x = $(val60[$val42*($val77-1)+1])+1  to $(val60[$val42*$val77+1])

tmp=!trim $val75	$(tmp0)
val75=!translate internal $	\
$ to ;; in $tmp
tmp0=!makelist x for x = $(val60[$val42*($val77-1)+1])+1  to $(val60[$val42*$val77+1])

tmp=!trim $val76	$(tmp0)
val76=!translate internal $	\
$ to ;; in $tmp
val77=$[rint($val77 + 1)]
val78=$(val60[$val42*($val77-1)+1])
!endwhile
oefsteps=$val75 
nextstep=!nosubst $val75 
!readproc oef/steps.proc
replytype1=mark
replyname1=
replygood1=$(val55[1;]);$(val57[1;])
replytype2=mark
replyname2=
replygood2=$(val55[2;]);$(val57[2;])
replytype3=mark
replyname3=
replygood3=$(val55[3;]);$(val57[3;])
replytype4=mark
replyname4=
replygood4=$(val55[4;]);$(val57[4;])
replytype5=mark
replyname5=
replygood5=$(val55[5;]);$(val57[5;])
replytype6=mark
replyname6=
replygood6=$(val55[6;]);$(val57[6;])
replytype7=mark
replyname7=
replygood7=$(val55[7;]);$(val57[7;])
replytype8=mark
replyname8=
replygood8=$(val55[8;]);$(val57[8;])
replytype9=mark
replyname9=
replygood9=$(val55[9;]);$(val57[9;])
replytype10=mark
replyname10=
replygood10=$(val55[10;]);$(val57[10;])
replytype11=mark
replyname11=
replygood11=$(val55[11;]);$(val57[11;])
replytype12=mark
replyname12=
replygood12=$(val55[12;]);$(val57[12;])
replytype13=mark
replyname13=
replygood13=$(val55[13;]);$(val57[13;])
replytype14=mark
replyname14=
replygood14=$(val55[14;]);$(val57[14;])
replytype15=mark
replyname15=
replygood15=$(val55[15;]);$(val57[15;])
replytype16=mark
replyname16=
replygood16=$(val55[16;]);$(val57[16;])
replytype17=mark
replyname17=
replygood17=$(val55[17;]);$(val57[17;])
replytype18=mark
replyname18=
replygood18=$(val55[18;]);$(val57[18;])
replytype19=mark
replyname19=
replygood19=$(val55[19;]);$(val57[19;])
replytype20=mark
replyname20=
replygood20=$(val55[20;]);$(val57[20;])
replytype21=mark
replyname21=
replygood21=$(val55[21;]);$(val57[21;])
replytype22=mark
replyname22=
replygood22=$(val55[22;]);$(val57[22;])
replytype23=mark
replyname23=
replygood23=$(val55[23;]);$(val57[23;])
replytype24=mark
replyname24=
replygood24=$(val55[24;]);$(val57[24;])
replytype25=mark
replyname25=
replygood25=$(val55[25;]);$(val57[25;])
replytype26=mark
replyname26=
replygood26=$(val55[26;]);$(val57[26;])
replytype27=mark
replyname27=
replygood27=$(val55[27;]);$(val57[27;])
replytype28=mark
replyname28=
replygood28=$(val55[28;]);$(val57[28;])
replytype29=mark
replyname29=
replygood29=$(val55[29;]);$(val57[29;])
replytype30=mark
replyname30=
replygood30=$(val55[30;]);$(val57[30;])
replytype31=mark
replyname31=
replygood31=$(val55[31;]);$(val57[31;])
replytype32=mark
replyname32=
replygood32=$(val55[32;]);$(val57[32;])
replytype33=mark
replyname33=
replygood33=$(val55[33;]);$(val57[33;])
replytype34=mark
replyname34=
replygood34=$(val55[34;]);$(val57[34;])
replytype35=mark
replyname35=
replygood35=$(val55[35;]);$(val57[35;])
replytype36=mark
replyname36=
replygood36=$(val55[36;]);$(val57[36;])
replytype37=mark
replyname37=
replygood37=$(val55[37;]);$(val57[37;])
replytype38=mark
replyname38=
replygood38=$(val55[38;]);$(val57[38;])
replytype39=mark
replyname39=
replygood39=$(val55[39;]);$(val57[39;])
replytype40=mark
replyname40=
replygood40=$(val55[40;]);$(val57[40;])
question=__EXECUTED_1692754_EXERCISE__

!goto stat

!exit

:question
$()$val47$val53 $val8	   
!if $val48 notsametext  
$() 
!read oef/special.phtml help reading,[à lire] 
$() 
!endif
$()	   
!if $val50 notsametext  
$() 
!read oef/special.phtml help image,[à regarder] 
$() 
!endif
$()	  $val49$val51	   
!if $val73=1 
$()<center>$(val58[1]) 	    
!for m_s = 1 to $(val59[1]) 
$() 
!read oef/embed.phtml reply 1,\s 
$() 
!next
$()	   </center> 
!else
$()	    <ol>	      
!for m_t in  $(val76[$m_step;]) 
$() <li> $(val58[$m_t]) 	         
!for m_s = 1 to $(val59[$m_t]) 
$() 
!read oef/embed.phtml reply \t,\s 
$() 
!next
$() 	        </li> 
!next
$()	     </ol>	    
!endif
$()	
$()
!exit

:hint
$()
$()
!exit

:help
$()
$()
!exit

:solution
$()
$()
!exit

:latex
$()
$()
!exit

:feedback

!exit

:test

!exit

:stat
vsavelist=8,47,48,49,50,51,53,58,59,73,76
embedcnt=4
