View Full Version : Infinite Loop?
Brandtrock
12-17-2004, 11:47 PM
A programmer had been missing from work for over a week when finally someone noticed and called the cops.
They went round to his home and broke the door down. They found him dead in the still running shower with an empty bottle of shampoo next to his body. Apparently he'd been washing his hair.
The instructions on the bottle said:
Wet hair
Apply shampoo
Wait 2 minutes
Rinse
Repeat
:rofl
Zack Barresse
12-18-2004, 01:29 AM
Sub RepairError
Dim Me As Myself, Retard As AlterEgo
Do
MsgBox "I will not be a retard!", vbInformation, "Doh!"
Loop Until Me <> Retard
MsgBox "All better now!", vbExclamation, "Whew!"
End Sub
Jacob Hilderbrand
12-18-2004, 02:03 AM
Yeah, they really should add some error handling or use a better loop in shampoo instructions.
Option Explicit
Sub HairCleaning
Dim i As Long
Dim MyTimer As Double
For i = 1 to 2 'Change as required depending on how dirty your hair is.
Me.Body("Head").Hair.Wet =True
Me.Body("Head").Hair.AddItem("Shampoo")
MyTimer = Now
Do
Loop While Now - MyTimer < TimeSerial(0, 2, 0)
Me.Body("Head").Hair.Clear
Next i
End Sub
With just a little bit of thought, this tragedy could have been avoided. :rofl
Ken Puls
12-18-2004, 04:31 PM
Hey Jake,
I don't know if I agree with one line there...
Wouldn't Me.Body("Head").Hair.Clear make you bald? :eek:
Jacob Hilderbrand
12-18-2004, 05:30 PM
Hmmm... Well that's why it's always good to have someone else beta test your code. :)
Powered by vBulletin® Version 4.2.5 Copyright © 2025 vBulletin Solutions Inc. All rights reserved.