Imports System
Imports uCalcSoftware
Public Module Program
   Public Sub Main()
      Dim uc As New uCalc()
      Dim t = uc.NewTransformer()
      t.Str("<h1>Header</h1><p>Paragraph 1.</p><p>Paragraph 2.</p>")
      
      '// Define rules for different tags
      Dim h1Rule = t.Pattern("<h1>{text}</h1>")
      Dim pRule = t.Pattern("<p>{text}</p>")
      t.Find()
      
      '// Get the total count of all matches from all rules
      Console.WriteLine($"Total matches (all rules): {t.Matches.Count()}")
      
      '// Get the count for only the paragraph rule
      Console.WriteLine($"Paragraph matches only: {pRule.Matches.Count()}")
   End Sub
End Module