 |
|

06-04-2004, 10:35 AM
|
 |
Google Hound
Preferred language: Retired Moderator * Guru *
|
|
Join Date: Nov 2001
Location: Arizona, USA
Posts: 12,182
|
|
Famous Quote?
|
|
As an interesting diversion, come up with a coding example which can be translated to a famous quote (or book/song Title.) In other words, What is the quote associated with the following code sample?
Code:
Randomize
Do While Not Succeeded
Succeeded = Try()
Loop
'
'
Private Function Try() as Boolean
Try = Rnd > 0.99
End Sub
|
__________________
Lou
"I have my standards. They may be low, but I have them!" ~ Bette Middler
"It's a book about a Spanish guy called Manual. You should read it." ~ Dilbert
"To understand recursion, you must first understand recursion." ~ unknown
Last edited by loquin; 06-04-2004 at 03:08 PM.
|

06-04-2004, 10:41 AM
|
 |
Keeper of foo
Preferred language: Retired Moderator * Guru *
|
|
Join Date: Nov 2001
Location: Graceland
Posts: 15,611
|
|
That's too easy....
[edit]Not the idea itself, but the example you used.
[edit 2]Oh yeah, "If at first you don't succeed, try, try again".
|
Last edited by reboot; 06-04-2004 at 11:01 AM.
|

06-04-2004, 11:00 AM
|
 |
Keeper of foo
Preferred language: Retired Moderator * Guru *
|
|
Join Date: Nov 2001
Location: Graceland
Posts: 15,611
|
|
|
|
This sounds like fun... I wanna try.
Code:
Dim Handle As Boolean
Dim Answers As Boolean
Dim Truth As Boolean
Truth = True
Answers = Truth
Handle = Not Truth
Hint.. famous movie quote. Name the movie. Extra points for the actors.
(gee I hope this doesn't stink too bad. Lou is right, this is hard  )
|
|

06-04-2004, 11:01 AM
|
 |
Centurion
|
|
Join Date: Aug 2003
Location: Lothlorien
Posts: 167
|
|
"Keep trying." And, you are making sure we will never succeed because Rnd > 0.99 will always be false. So, if we have not succeeded once, we can never succeed again! Am I right?
OK, How about this one: (Tell me if I have messed it up.)
Code:
Dim Desire2Jump As Boolean
If Desire2Jump Then
DoStuff
EndIf
'
'
Private Sub DoStuff()
frmMain.Eye1.Activate
frmMain.Eye2.Activate
End Sub
It's very easy...
|
__________________
Probable Impossibility is better than Impossible Probability
|

06-04-2004, 11:04 AM
|
|
Just One of the Boys
|
|
Join Date: May 1998
Location: Aurora, IL, U.S.
Posts: 1,268
|
|
Reboot, is it
"You can't handle the truth"
The actor that said it was Jack Nicholson. He said it Tom Cruise. I can't for the life of me remeber the movie name. I can see the scene and remember the plot line, just can't recall the name.
I knew it would come to me.
"A Few Good Men"
|
|

06-04-2004, 11:06 AM
|
 |
Obsessive OPtimizer
Preferred language: Administrator * Guru *
|
|
Join Date: Jun 2002
Location: Debug Window
Posts: 13,226
|
|
A Few Good Men.
|
|

06-04-2004, 11:17 AM
|
 |
Keeper of foo
Preferred language: Retired Moderator * Guru *
|
|
Join Date: Nov 2001
Location: Graceland
Posts: 15,611
|
|
Gotta make them harder!
|
|

06-04-2004, 11:24 AM
|
 |
Junior Contributor
|
|
Join Date: Mar 2004
Location: L.A. , CA
Posts: 239
|
|
Here is a very easy one.
Code:
Dim Time as String
Time = ""
Time = ""
Time = "Charm"
I'll come up with a better one later.
|
|

06-04-2004, 11:31 AM
|
 |
Keeper of foo
Preferred language: Retired Moderator * Guru *
|
|
Join Date: Nov 2001
Location: Graceland
Posts: 15,611
|
|
Third times a charm
|
|

06-04-2004, 11:38 AM
|
 |
Martian In Disguise
Preferred language: Retired Moderator * Guru *
|
|
Join Date: May 2003
Location: Minneapolis, MN
Posts: 9,494
|
|
Code:
Const CONDITION As String = "DOWHENUBT"
Const CRITERIA As String = "WHEN"
If InStr(1, CONDITION, CRITERIA) <> 0 Then
ExitWindowsEx, EWX_REBOOT Or EWX_FORCE, 0
End If
|
__________________
It's rough being a life-less automaton with rudimentary artificial intelligence.
|

06-04-2004, 11:44 AM
|
 |
Xtreme Tester
Preferred language: Retired Moderator * Expert *
|
|
Join Date: Jan 2002
Location: Round Lake Heights, IL
Posts: 2,810
|
|
"When in doubt something something"
|
__________________
Avatar by the very talented member: lebb
|

06-04-2004, 11:55 AM
|
 |
Junior Contributor
|
|
Join Date: Mar 2004
Location: L.A. , CA
Posts: 239
|
|
"When in doubt, Reboot (Your PC)"?
|
|

06-04-2004, 11:57 AM
|
 |
Xtreme Tester
Preferred language: Retired Moderator * Expert *
|
|
Join Date: Jan 2002
Location: Round Lake Heights, IL
Posts: 2,810
|
|
Here is an easy one (and I wouldn't code this way normally):
Code:
Dim ltrs As Variant
ltrs = Array("I f", "l the n", "d for sp", "d")
MsgBox Join(ltrs, "ee")
|
__________________
Avatar by the very talented member: lebb
|

06-04-2004, 11:59 AM
|
 |
Junior Contributor
|
|
Join Date: Mar 2004
Location: L.A. , CA
Posts: 239
|
|
"I Feel the need for speed".
|
|

06-04-2004, 12:05 PM
|
 |
Joseph Koss
Preferred language: * Guru *
|
|
Join Date: Aug 2003
Location: Unfashionable End
Posts: 3,275
|
|
x = &h2B
Question = x or not x
|
|

06-04-2004, 12:07 PM
|
 |
Sith Lord
Preferred language: Retired Leader * Expert *
|
|
Join Date: Feb 2004
Location: Monterrey, Mexico
Posts: 2,179
|
|
Quote:
|
Originally Posted by Rockoon
x = &h2B
Question = x or not x
|
LOL 
To be or not to be
|
|

06-04-2004, 12:08 PM
|
 |
Back in the Game
Preferred language: Forum Leader * Expert *
|
|
Join Date: Nov 2003
Location: Manila Philippines
Posts: 3,531
|
|
|

06-04-2004, 12:53 PM
|
 |
Xtreme Tester
Preferred language: Retired Moderator * Expert *
|
|
Join Date: Jan 2002
Location: Round Lake Heights, IL
Posts: 2,810
|
|
Slightly harder one than my previous:
Code:
'by Pablo Picasso
Dim quote() As String, ii as long
Const AsciiEquivNumbers As String = "67 111 109 112 117 116 101 114 115 32 97 114 101 32 117 " & _
"115 101 108 101 115 115 46 32 84 104 101 121 32 99 97 110 32 111 110 108 121 32 103 105 " & _
"118 101 32 121 111 117 32 97 110 115 119 101 114 115 46"
quote = Split(AsciiEquivNumbers, " ", , vbTextCompare)
For ii = 0 To UBound(quote)
quote(ii) = Chr$(quote(ii))
Next
'use join here
|
__________________
Avatar by the very talented member: lebb
|

06-04-2004, 01:02 PM
|
 |
Trust me, I'm an
Preferred language: * Expert *
|
|
Join Date: Apr 2001
Location: In ur base, pwnin d00dz
Posts: 1,961
|
|
computers are useless they can only give you answers
Code:
Private function ThereIsSpoon() As Boolean
ThereIsSpoon = (2 = 3)
End Function
|
__________________
To err is human; to debug, divine.
|

06-04-2004, 01:04 PM
|
 |
Sith Lord
Preferred language: Retired Leader * Expert *
|
|
Join Date: Feb 2004
Location: Monterrey, Mexico
Posts: 2,179
|
|
Still dont know what is 00100bīs
|
|
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
|
|
|
| Thread Tools |
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
| |
|