!set title=Construcción de la igualdad 8
!if $wims_read_parm!=$empty
 !goto $wims_read_parm
!endif
oef2wims_version=3.22
language=fr
author=XIAO, Gang
email=xiao@unice.fr
computeanswer=no
precision=10000

ansorder=r,r,r,r
varcnt=31
prevarcnt=27
postvarcnt=3
replycnt=4
choicecnt=0
conditioncnt=1
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=$[rint(8)]
val7=1,2,3,4,5,6,8,10
tmp0=!itemcnt $val7

val8=$[rint($(tmp0))]
val9=1/2,3/2,5/2,1/3,2/3,4/3,5/3,	1/4,3/4,5/4,1/5,2/5,3/5,4/5,6/5,1/6,5/6
val10=
!for val11  in $val9 
tmp0=!translate / to , in $val11

val12=$(tmp0)
tmp0=!values $(val12[1])*x for x in $val7

val13=$(tmp0)
tmp0=!values $(val12[2])*x for x in $val7

val14=$(tmp0)
val15=
!for val16 =1 to $val8 
tmp0=!append item $(val13[$val16])/$(val14[$val16]) to $val15

val15=$(tmp0)
!next
tmp0=!shuffle $val15

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

tmp=!nonempty rows $tmp
tmp=!randrow $tmp
tmp0=!translate internal $\
$ to ; in $tmp
val9=$(tmp0)
tmp0=!translate internal / to , in $(val9[1])

val17=$(tmp0)
tmp0=!translate internal / to , in $(val9[2])

val18=$(tmp0)
tmp0=!translate internal / to , in $val10

val10=$(tmp0)
tmp0=!rows2lines $val10

tmp1=!lines2items $(tmp0)

val10=$(tmp1)
tmp0=!listuniq $val10

val10=$(tmp0)
tmp0=!listcomplement $val17,$val18 in $val10

val10=$(tmp0)
val19=<HR noshade size=2>
val20=<font size=+2>
val21=</font>
!if $val6>4 
tmp0=!shuffle $val10

tmp1=!item 1 to $val6-4 of $(tmp0)

val10=,$(tmp1)
tmp0=!replace internal , by $val21,$val20 in $val20$val10$val21

val10=$(tmp0)
!else
val10=
!endif
val22=50x40x1
replytype1=dragfill
replyname1=Numerador 1
replygood1=?analyze 23;$val20$(val17[1])$val21 $val10
replytype2=dragfill
replyname2=Denominador 1
replygood2=?analyze 24;$val20$(val17[2])$val21
replytype3=dragfill
replyname3=Numerador 2
replygood3=?analyze 25;$val20$(val18[1])$val21
replytype4=dragfill
replyname4=Denominador 2
replygood4=?analyze 26;$val20$(val18[2])$val21
question=__EXECUTED_1692754_EXERCISE__

!goto stat

!exit

:question
$()Construye dos facciones iguales a partir de los números dados más	abajo.	<p><center><table border=0>	<tr>	<td align=center> 
!read oef/embed.phtml reply 1,$val22 
$()</td>	<td align=center rowspan=3>$val20&nbsp;&nbsp;=&nbsp;&nbsp;$val21</td>	<td align=center> 
!read oef/embed.phtml reply 3,$val22 
$()</td>	</tr><tr>	<td align=center width=$m_fw>$val19</td>	<td align=center width=$m_fw>$val19</td>	</tr><tr>	<td align=center> 
!read oef/embed.phtml reply 2,$val22 
$()</td>	<td align=center> 
!read oef/embed.phtml reply 4,$val22 
$()</td>	</tr></table></center>	
$()
!exit

:hint
$()
$()
!exit

:help
$()
$()
!exit

:solution
$()
$()
!exit

:postdef
tmp0=!replace internal $val20 by in $val23,$val24,$val25,$val26

val27=$(tmp0)
tmp0=!replace internal $val21 by in $val27

val27=$(tmp0)
val28=$[rint($(val27[1])*$(val27[4])-$(val27[2])*$(val27[3]))]

!exit

:feedback

!exit

:test

!ifval ? notin $val27 and $(val27[1])*$(val27[2])*$(val27[3])*$(val27[4])>0 and $val28 issametext 0
 condtest1=1
!else
 condtest1=0
!endif
condname1=\($(val27[1])/($(val27[2])) = $(val27[3])/($(val27[4])))

!exit

:stat
vsavelist=19,20,21,22,23,24,25,26
embedcnt=4
