| |
|
|
p.specht
|
Window Title "Dreisatz-coach for young Kopfrechner"
'Program 'Dreisatz-coach' (CL) CopyLeft 2014-11 by Heinz Brill
'Adaptiert for XProfan 11 by P.woodpecker, Wien. without jedwede Gewähr!
Window Style 24:Randomize:font 2:Window %maxx/6,%maxy/6-%maxx*4/6,%maxy*4/6
Declare s$,Dreisatz$[],Var1&[],Var2&,zaehler&,erg&
Set("RegEx",1):Var pos&=1
Dreisatz$[0]="4 eggs cost 80 cent, how much cost 3 eggs ?"
Dreisatz$[1]="5 men drink 20 glass beer, how much drink 8 men, if eachone gleichviel drink ?"
Dreisatz$[2]="7 Hühner lay 42 eggs on the day. how much eggs lay 12 Hühner on the day, if each gleichviel places ?"
Dreisatz$[3]="3 machines finished 1200 Piece on the day. how much finished 10 machines ?"
Dreisatz$[4]="6 Puttls quarzen 240 Ipfeln per Zast. how much quarzen 10 Puttls ?"
Dreisatz$[5]="If 1 man 50 Zast daily earn , how much Zaster earn then 3 men durchschnittlich?"
Dreisatz$[6]="If 1 Heinz in the incision 3 programs daily program , wieviele create 4 similar gifted Programmer on the day?"
WhileLoop 0,sizeof(Dreisatz$[])-1
zaehler&=0:pos&=1:Clear Var1&[]
While pos& :pos&=Instr("[0-9]{1,}",Dreisatz$[&Loop],pos&)
If pos&>0
Var1&[zaehler&]=Val($Match)
Inc zaehler&
pos&=pos&+4'because of several possible to put (here To Tausender)
EndIf
EndWhile
Print "\n "+Dreisatz$[&Loop]
Print " "+"Dein Result?: ";:Input Var2&
erg&=(Var1&[1]/Var1&[0])*Var1&[2]
If Var2&=erg&
Print " "+"Das is correctly.!"
Else
Print " "+"Leider wrong! ";
Print " "+"Richtig would ";erg&;" been!"
EndIf
print mkstr$("-",80)
if %csrlin>32:waitinput:cls:endif
EndWhile
Print "[Button] to that terminate..."
WaitInput
End
|
|
|
| XProfan 11Computer: Gerät, daß es in Mikrosekunden erlaubt, 50.000 Fehler zu machen, zB 'daß' statt 'das'... | 05/15/21 ▲ |
|
|
|