Beste Online Casinos
Text(ver)dreher
[Windows 95/98/NT/2000]

15.11.1999


Wie viel verschiedene "Worte" kann man aus dem Wort "Hallo" erstellen ?
��� Auch wenn es keine richtigen Worte sind,
��� kann man das Wort Hallo immerhin auf 120 verschiedene Arten darstellen...

��� Hallo, Halol, Hallo, Halol, Haoll, Haoll, Hlalo, Hlaol, Hllao, Hlloa usw.

��� Und so geht es:

ERFORDERLICHE OBJEKTE
   1 Listbox (List1)
   2 CommandButtons (Command1, Command2)
   1 Textbox (Text1)
 FORM-CODE
   Sub Textdreher(x As String, y As String)
      Dim i As Integer, j As Integer
      j = Len(y)
      If j < 2 Then
         List1.AddItem x & y
         List1.ListIndex = List1.ListCount - 1
         Caption = List1.ListCount & " M�glichkeiten"
      Else
         For i = 1 To j
            Call Textdreher(x + Mid(y, i, 1), Left(y, i - 1) + _
               Right(y, j - i))
         Next i
      End If
   End Sub
   Private Sub Command1_Click()
      List1.Clear
      Call Textdreher("", Text1.Text)
   End Sub
   Private Sub Command2_Click()
      Unload Me
   End Sub
   Private Sub Form_Load()
      Command1.Caption = "&Start"
      Command2.Caption = "&Beenden"
      Text1.Text = "Hallo"
   End Sub

Download - 2 KB

Check these out