Imports System
Imports uCalcSoftware
Public Module Program
   Public Sub Main()
      Dim uc As New uCalc()
      Dim t = uc.NewTransformer()
      Dim ruleA = t.FromTo("a", "A")
      Dim ruleB = t.FromTo("b", "B")
      ruleA.GlobalMinimum = 3
      
      '// Case 1: Fails (only 2 'a's)
      Console.WriteLine("--- Case 1: Fails ---")
      t.Text = "a b a b"
      t.Transform()
      Console.WriteLine($"Matches Found: {t.Matches.Count()}") '// Should be 0
      Console.WriteLine($"Result: {t}")
      
      '// Case 2: Succeeds (3 'a's)
      Console.WriteLine("")
      Console.WriteLine("--- Case 2: Succeeds ---")
      t.Text = "a b a b a"
      t.Transform()
      Console.WriteLine($"Matches Found: {t.Matches.Count()}") '// Should be 5 (3 'A's and 2 'B's)
      Console.WriteLine($"Result: {t}")
   End Sub
End Module