Dtvscrotes Posted August 18, 2007 Share Posted August 18, 2007 (edited) I tried to make a basic math trick to work on my computer. The trick works like this. You tell someone to think of a four digit #. Tell them they cant show u and say write it on a piece of paper. You tell them to jumble those digits to make a new #. write this on the paper as well. Subtract the smaller # from the larger # to make a new number. write the new number down. Now circle one of the digits in the new number but u cant circle 0 because they r already circles. Remove the circled digit. Then show those left over numbers to me. Now you say i know wat number u circled. Now u add the leftover digits together lets say this is A. -If the sum(A) is below 9 then subtract A from 9. (this answer is the number they circled.) - If the sum(A) is below 18(above 9) then subtract A from 18.(this answer is the number they circled) - If the sum(A) is below 27 (above 18) then subtract A from 27.(this answer is the number they circled) - if the sum(A) is equal 9, 18 or 27 then the number they circled is 9 (or 0 if they cheated.) Im not sure how it works but it does. ex.A) 5476-4567=0909 0(9)09 left over = 009 0 + 0 + 9 = 9 they removed a 9. ex. 7429-4972=2457 24(5)7 leftover = 247 2+4+7 = 13 18-13 = 5 they removed a 5. Now i made a basic script so i dont have to go through the process of doing tricks to friends. My PC can do it for me but it's not working. Ex. A) will end up as 918 Ex.= equals 514 notice the two added digits equal the first digit? 9 1+8 5 1+4 I dont understand PLZ HELP? If you figure it out plz email x_shadow_x21@hotmail.com with the correct script plz. I will be very thankful and if u can explain what i did wrong so i will learn from my mistakes. TY I'll copy paste my script. MsgBox(0,"title", "Think of a four digit number.") MsgBox(0,"title", "Now Rearrange that number to make a different number.") MsgBox(0,"title", "Now subtract the smaller of the two numbers from the larger number.") MsgBox(0,"title", "Now circle one of the numbers in your answer. Do not circle a zero because it is already a circle.") $number1=Inputbox("question", "Please type in your first leftover digit.") $number2=Inputbox("question", "Please type in your second leftover digit.") $number3=Inputbox("question", "Please type in your third leftover digit.(leave blank if there was no third digit)") Sleep(1000) Run("notepad.exe") Sleep(2000) Send("The number you circled was:") $var=$number1+ $number2+ $number3 IF $var<9 Then Send(9-$var) IF $var<18 Then Send(18-$var) IF $var<27 Then Send(27-$var) IF $var=9 or $var = 18 or $var = 27 Then Send(9) Edited August 18, 2007 by Dtvscrotes Link to comment Share on other sites More sharing options...
martin Posted August 18, 2007 Share Posted August 18, 2007 I tried to make a basic math trick to work on my computer. The trick works like this. You tell someone to think of a four digit #. Tell them they cant show u and say write it on a piece of paper. You tell them to jumble those digits to make a new #. write this on the paper as well. Subtract the smaller # from the larger # to make a new number. write the new number down. Now circle one of the digits in the new number but u cant circle 0 because they r already circles. Remove the circled digit. Then show those left over numbers to me. Now you say i know wat number u circled. Now u add the leftover digits together lets say this is A. -If the sum(A) is below 9 then subtract A from 9. (this answer is the number they circled.) - If the sum(A) is below 18(above 9) then subtract A from 18.(this answer is the number they circled) - If the sum(A) is below 27 (above 18) then subtract A from 27.(this answer is the number they circled) - if the sum(A) is equal 9, 18 or 27 then the number they circled is 9 (or 0 if they cheated.) Im not sure how it works but it does. ex.A) 5476-4567=0909 0(9)09 left over = 009 0 + 0 + 9 = 9 they removed a 9. ex. 7429-4972=2457 24(5)7 leftover = 247 2+4+7 = 13 18-13 = 5 they removed a 5. Now i made a basic script so i dont have to go through the process of doing tricks to friends. My PC can do it for me but it's not working. Ex. A) will end up as 918 Ex.= equals 514 notice the two added digits equal the first digit? 9 1+8 5 1+4 I dont understand PLZ HELP? If you figure it out plz email x_shadow_x21@hotmail.com with the correct script plz. I will be very thankful and if u can explain what i did wrong so i will learn from my mistakes. TY I'll copy paste my script. MsgBox(0,"title", "Think of a four digit number.") MsgBox(0,"title", "Now Rearrange that number to make a different number.") MsgBox(0,"title", "Now subtract the smaller of the two numbers from the larger number.") MsgBox(0,"title", "Now circle one of the numbers in your answer. Do not circle a zero because it is already a circle.") $number1=Inputbox("question", "Please type in your first leftover digit.") $number2=Inputbox("question", "Please type in your second leftover digit.") $number3=Inputbox("question", "Please type in your third leftover digit.(leave blank if there was no third digit)") Sleep(1000) Run("notepad.exe") Sleep(2000) Send("The number you circled was:") $var=$number1+ $number2+ $number3 IF $var<9 Then Send(9-$var) IF $var<18 Then Send(18-$var) IF $var<27 Then Send(27-$var) IF $var=9 or $var = 18 or $var = 27 Then Send(9) The script returns 9189 (NOT 918 AS YOU SAY) because you have asked it to without realising. The value of $var is 9 so IF $var<9 Then Send(9-$var) ;not less than 9 so ignore IF $var<18 Then Send(18-$var) ;less than 18 so send 9 IF $var<27 Then Send(27-$var) ;less than 27 so send 18 IF $var=9 or $var = 18 or $var = 27 Then Send(9); = 9 so send 9 What you need is nore like IF $var=9 or $var = 18 or $var = 27 Then Send(9) ElseIf $var<9 Then Send(9-$var) ElseIF $var<18 Then Send(18-$var) ElseIF $var<27 Then Send(27-$var) EndIf Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script. Link to comment Share on other sites More sharing options...
Dtvscrotes Posted August 18, 2007 Author Share Posted August 18, 2007 (edited) there r still extra digits on the end of the answer Edited August 18, 2007 by Dtvscrotes Link to comment Share on other sites More sharing options...
martin Posted August 18, 2007 Share Posted August 18, 2007 there r still extra digits on the end of the answer This is the code you posted, except that I've changed the end part as I indicated in my reply. I don't get any extra digits. MsgBox(0,"title", "Think of a four digit number.") MsgBox(0,"title", "Now Rearrange that number to make a different number.") MsgBox(0,"title", "Now subtract the smaller of the two numbers from the larger number.") MsgBox(0,"title", "Now circle one of the numbers in your answer. Do not circle a zero because it is already a circle.") $number1=Inputbox("question", "Please type in your first leftover digit.") $number2=Inputbox("question", "Please type in your second leftover digit.") $number3=Inputbox("question", "Please type in your third leftover digit.(leave blank if there was no third digit)") Sleep(1000) Run("notepad.exe") Sleep(2000) Send("The number you circled was:") $var=$number1+ $number2+ $number3 #cs ;This section is from you original post IF $var<9 Then Send(9-$var) IF $var<18 Then Send(18-$var) IF $var<27 Then Send(27-$var) IF $var=9 or $var = 18 or $var = 27 Then Send(9) #ce ;Replaced with this bit below IF $var=9 or $var = 18 or $var = 27 Then Send(9) ElseIf $var<9 Then Send(9-$var) ElseIF $var<18 Then Send(18-$var) ElseIF $var<27 Then Send(27-$var) EndIf Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script. Link to comment Share on other sites More sharing options...
Dtvscrotes Posted August 18, 2007 Author Share Posted August 18, 2007 Ty Martin This seems to works with the once ive tested it with so TY. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now