Name: butts 2007-09-18 9:48 ID:O/2Xz6BT
def command_butts
print("butts")
command_butts
print("butts")
command_butts
Namespace Scalable
Module Enterprise
Class Solution
Shared Sub Main()
Dim WordToPrint As String 'This will hold the string our customer wants to print
start:
Console.Write("Please enter the string you wish to print: ") 'Asks the consumer for a string
WordToPrint = Console.ReadLine() 'Gets the string the client inputs
'Checking phase
If WordToPrint.ToLower <> "butts" Then GoTo ButtsError Else GoTo PrintButts 'I couldn't figure out why IsNot didn't work but thanks Rob for teaching me about <>
GoTo start
ButtsError:
ButtsError() 'Shows an error due to an incompatible input
GoTo start
PrintButts:
PrintString(WordToPrint) 'Prints the string the user desires
End Sub
Shared Function PrintString(ByVal MyString As String) 'Thanks Dave
Console.WriteLine(MyString) 'Outputs desired string
Console.WriteLine("Press any key to quit.")
Console.ReadKey() 'Waits for the user to press a key
Return 1
End Function
Shared Function ButtsError()
Console.WriteLine("We're sorry, but the requested feature is currently unavailable.")
Console.WriteLine("Press any key to continue.")
Console.ReadKey() 'Waits for the user to press a key
Return 2
End Function
End Class
End Module
End Namespace