input: Write a function to convert a given Python program to a C# program. The function should take a Python function as input and return the equivalent C# function. Ensure that the function names and data types are correctly converted.
  assert convert_python_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: def convert_python_to_csharp(python_code):
      lines = python_code.strip().split('\n')
      function_name = lines[0].split('(')[0].split(' ')[1]
      params = lines[0].split('(')[1].split(')')[0].split(', ')
      csharp_params = ', '.join([f'int {param}' for param in params])
      csharp_code = f'public int {function_name.capitalize()}({csharp_params})\n{{\n'
      for line in lines[1:]:
          if 'def' in line:
              continue
          line = line.replace('if', 'if (').replace(':', ')')
          line = line.replace('return', 'return ').replace('\n', '')
          line = line.replace('else:', 'else')
          line = line.replace('power', 'Power')
          line += ';'
          csharp_code += f'    {line}\n'
      csharp_code += '}'
      return csharp_code