input: 
  def power_to_csharp(python_code: str) -> str:
      """Convert a given Python function to a C# function.
      The input is a string representing the Python function. The output is a string
      representing the equivalent C# function. The function provided calculates the 
      power of a number using recursion.
      >>> power_to_csharp("def power(x, y):\n    if y == 0:\n        return 1\n    else:\n        return x * power(x, y - 1)")
      'public int Power(int x, int y)\n{\n    if (y == 0)\n    {\n        return 1;\n    }\n    else\n    {\n        return x * Power(x, y - 1);\n    }\n}'
      """
  
output:     python_code = python_code.strip()
      lines = python_code.split('\n')
      csharp_code = []
  
      for line in lines:
          line = line.strip()
          if line.startswith("def "):
              function_name = line.split('(')[0].split(' ')[1]
              params = line.split('(')[1].split(')')[0].split(', ')
              param_types = ', '.join([f"int {param}" for param in params])
              csharp_code.append(f"public int {function_name}({param_types})")
              csharp_code.append("{")
          elif line.startswith("if "):
              condition = line.split('if ')[1].split(':')[0]
              csharp_code.append(f"    if ({condition})")
              csharp_code.append("    {")
          elif line.startswith("else:"):
              csharp_code.append("    }")
              csharp_code.append("    else")
              csharp_code.append("    {")
          elif line.startswith("return "):
              return_value = line.split('return ')[1]
              csharp_code.append(f"        return {return_value};")
          elif line == "":
              csharp_code.append("    }")
              csharp_code.append("}")
  
      return '\n'.join(csharp_code)