import clr clr.AddReference("System") from System import DateTime now = DateTime.Now print(now)
import clr clr.AddReference("MyAssembly") from MyAssembly import MyClass my_obj = MyClass() my_obj.MyMethod()In this example, the "MyAssembly" .NET assembly is added as a reference, and the MyClass class is imported from it. The code then creates an instance of the MyClass class and calls the MyMethod method. Package Library: The clr package is part of the .NET Framework and is included in the Python Standard Library.