!set title=Click en la tabla
!if $wims_read_parm!=$empty
 !goto $wims_read_parm
!endif
oef2wims_version=3.22
language=en
author=XIAO Gang
email=xiao@unice.fr

ansorder=r
varcnt=48
prevarcnt=46
postvarcnt=1
replycnt=1
choicecnt=0
conditioncnt=0
feedbackcnt=1
format=html

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

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

tmp0=!record 0 of table

val6=$(tmp0)
tmp=!translate internal $	$ to ; in $val6

tmp0=!rowcnt $tmp
val7=$[rint($(tmp0))]

!ifval $val2 notitemof 1,2,3,4
val2=$[rint(0)]
!endif

!ifval $val3 notitemof 1,2,3,4
val3=$[rint(0)]
!endif
val8=

!ifval $val4 issametext $val8 or $val4<7 or	 $val4>$val7
val4=$[rint(54)]
!endif
tmp0=!values x for x=1 to $val7

val9=$(tmp0)
tmp0=!listintersect $val5 and $val9

val5=$(tmp0)

!ifval $val2>0
val10=$[rint($val2)]
!else
tmp0=!randint 1, 4

val10=$[rint($(tmp0))]
!endif

!ifval $val3=$val2
val11=$[rint(0)]
!else
val11=$[rint($val3)]
!endif
tmp0=!listcomplement $val10 in 1,2,3,4

val12=$(tmp0)

!ifval \candouble issametext yes and $val10 != 1
val12=$val10,$val12
!endif

!ifval $val11>0 and $val11 isitemof $val12
val13=$[rint($val11)]
!else
tmp=!nonempty items $val12

tmp0=!randitem $tmp
val13=$[rint($(tmp0))]
!endif
tmp0=!record 0 of table

val14=$(tmp0)
val6=$val14
val8=
!if $val5 notsametext $val8 and \selective notsametext no 
tmp=!translate internal $	$ to ; in $val6

tmp=!row $val5 of $tmp
tmp0=!translate internal $\
$ to ; in $tmp
val6=$(tmp0)
!endif
tmp=!translate internal $	$ to ; in $val6

tmp=!column 3 of $tmp
tmp0=!translate internal $\
$ to ; in $tmp
val15=$(tmp0)
tmp=!translate internal $	$ to ; in $val6

tmp=!column 2 of $tmp
tmp0=!translate internal $\
$ to ; in $tmp
val16=$(tmp0)
tmp=!translate internal $	$ to ; in $val6

tmp0=!rowcnt $tmp
val17=$[rint(min($val4,$(tmp0)))]
tmp0=!record 0 of position

val18=$(tmp0)
val19=$val18
val8=
!if $val5 notsametext $val8 and \selective notsametext no 
tmp=!translate internal $	$ to ; in $val19

tmp=!row $val5 of $tmp
tmp0=!translate internal $\
$ to ; in $tmp
val19=$(tmp0)
!endif
tmp=!translate internal $	$ to ; in $val19

tmp=!column 3 of $tmp
tmp0=!translate internal $\
$ to ; in $tmp
val15=$(tmp0)
tmp=!translate internal $	$ to ; in $val19

tmp=!column 2 of $tmp
tmp0=!translate internal $\
$ to ; in $tmp
val16=$(tmp0)
tmp=!translate internal $	$ to ; in $val19

tmp0=!rowcnt $tmp
val20=$[rint(min($val4,$(tmp0)))]

!ifval $val10 isitemof 2,3
val21=$[rint($val10)]
!else
tmp=!nonempty items 2,3

tmp0=!randitem $tmp
val21=$[rint($(tmp0))]
!endif
tmp0=!randint 1, $val17

val22=$[rint($(tmp0))]
val23=$(val6[$val22;])
tmp0=!item 1 of $val23

val22=$[rint($(tmp0))]
val24=$[rint(30)]
val25=$[rint(30)]
tmp=!translate internal $	$ to ; in $val18

tmp=!column 4 of $tmp
tmp0=!translate internal $\
$ to ; in $tmp
val26=$(tmp0)
tmp=!translate internal $	$ to ; in $val18

tmp=!column 3 of $tmp
tmp0=!translate internal $\
$ to ; in $tmp
val27=$(tmp0)
val28=
!for val29 =1 to $val7 
val30=$[rint($(val26[$val29])*$val24)]
val31=$[rint($(val27[$val29])*$val25)]

!ifval $(val27[$val29])>8
val31=$[rint($val31+5)]
!endif

!ifval $(val27[$val29])>8
val30=$[rint($val30+$val24*2)]
!endif
val28=$val28 r,$val30,$val31,$val30+$val24,$val31+$val25;
!if $val29=$val22 
val32=r,$val30,$val31,$val30+$val24,$val31+$val25
!endif
!next
val33=$(val23[$val21])
val34=$(val14[;$val21])
val35=número, símbolo, nombre, masa atómica
replytype1=coord
replyname1=The position
replygood1=$val1/table2.gif;$val32;$val28
question=__EXECUTED_1692754_EXERCISE__

!goto stat

!exit

:question
$()En la tabla periódica de los elementos mostrada más abajo,	haz click en la casilla del elemento cuyo $(val35[$val21]) es $val33.	<p><center>	 
!read oef/embed.phtml r1 
$()	</center>	
$()
!exit

:hint
$()
$()
!exit

:help
$()
$()
!exit

:solution
$()
$()
!exit

:postdef
!if $m_result1>1 
val36=$(val34[$m_result1-1])
!endif

!exit

:feedback
!ifval $m_result1>1
 <p>	Has hecho click en la casilla de $val36 en lugar de la de $val33.	
$()
!endif

!exit

:test

!exit

:stat
vsavelist=21,33,34,35
embedcnt=1
