Imports System
Imports uCalcSoftware
Public Module Program
   Public Sub Main()
      Dim uc As New uCalc()
      Dim t As New uCalc.Transformer()
      
      '// A snippet of code where 'rate' is both a variable and part of a string
      Dim source_code = "rate = 0.05; // Set default rate
print(""Current rate is: "" + rate);"
      
      Console.WriteLine("Original Code:")
      Console.WriteLine(source_code)
      Console.WriteLine("")
      
      '// Define a rule to rename the VARIABLE 'rate' to 'annual_rate'
      t.FromTo("rate", "annual_rate")
      t.SkipOver("// {text}")
      
      '// Run the transformation. The 'rate' inside the string is untouched.
      Console.WriteLine("Transformed Code:")
      Console.WriteLine(t.Transform(source_code))
   End Sub
End Module