Jody Crothers
Head of Learning Area (Mathematics)
Ridge View Secondary College
Western Australia
Define lockedbox()=
Prgm
:Local comb
:Disp "Enter your code below you have 3 attempts"""
:tries:=0
:correct:=false
:While tries<3 and not correct
: comb:=0
: Request "End Combination",comb
:Disp comb
:If comb=2345 Then
: Disp "correct"
: correct:=true
:Else
: Disp "wrong"
: tries:=tries+1
:EndIf
:EndWhile
:If not correct Then
: Disp "No more attempts. Goodbye."
:Else
: Disp "You're in!"
:EndIf
:EndPrgm
Do good,
John
--
--
To post to this group, send email to tins...@googlegroups.com
To unsubscribe send email to tinspire+u...@googlegroups.com
For more options, visit this group at
http://groups.google.com.au/group/tinspire?hl=en-GB?hl=en-GB
The tns documents shared by group members are archived at
https://sites.google.com/site/tinspiregroup/classroom-news/welcome-abouttime
---
You received this message because you are subscribed to the Google Groups "tinspire" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tinspire+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/tinspire/SL2P216MB1048207B650B0431FF17E306B88E9%40SL2P216MB1048.KORP216.PROD.OUTLOOK.COM.
Suggestion: generate a random combination!
Do good,
John
To view this discussion on the web visit https://groups.google.com/d/msgid/tinspire/004f01d7d22a%24a4442df0%24eccc89d0%24%40optonline.net.
Jody Crothers
Head of Learning Area (Mathematics)
Ridge View Secondary College
Western Australia
Re: “Now how to hide the variable.”
That will be a challenge! All you’d have to do is add a Disp <var> to the program to reveal it.
You could put the combination into a document in the form of a Question and make the doc an exam to hide the answer…
Do good,
John
To view this discussion on the web visit https://groups.google.com/d/msgid/tinspire/SL2P216MB10487AB42E601AA2583C0AE0B88F9%40SL2P216MB1048.KORP216.PROD.OUTLOOK.COM.
You could conceal the program (delete the page containing the Program Editor app), clear the Calc app’s history to have a blank Calc app, then send the file to the students.
They would have to press [var] to paste the program name and then run the program.
But a clever student can always add a Program Editor, open the program and reveal the code.
I think the best solution to keep the code hidden would be to write the program using Lua!
Do good,
John
To view this discussion on the web visit https://groups.google.com/d/msgid/tinspire/000401d7d2fe%24c52ce960%244f86bc20%24%40optonline.net.
Jody Crothers
Head of Learning Area (Mathematics)
Ridge View Secondary College
Western Australia
See attached, Jody.
To view this discussion on the web visit https://groups.google.com/d/msgid/tinspire/000001d7d303%24969f3da0%24c3ddb8e0%24%40optonline.net.
Jody Crothers
Head of Learning Area (Mathematics)
Ridge View Secondary College
Western Australia