input: def convert_to_csharp(python_code: str) -> str:
      """
      Convert a given Python program to a C# program.
      >>> convert_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:     lines = python_code.split('\n')
      csharp_code = []
      indent_level = 0
      for line in lines:
          stripped_line = line.strip()
          if stripped_line.startswith('def '):
              function_name = stripped_line.split('(')[0].split(' ')[1]
              args = stripped_line.split('(')[1].split(')')[0].split(', ')
              csharp_args = ', '.join([f'int {arg}' for arg in args])
              csharp_code.append(f'public int {function_name}({csharp_args})')
              csharp_code.append('{')
              indent_level += 1
          elif stripped_line.startswith('if '):
              csharp_code.append(' ' * 4 * indent_level + f'if ({stripped_line[3:-1]})')
              csharp_code.append(' ' * 4 * indent_level + '{')
              indent_level += 1
          elif stripped_line.startswith('else:'):
              indent_level -= 1
              csharp_code.append(' ' * 4 * indent_level + '}')
              csharp_code.append(' ' * 4 * indent_level + 'else')
              csharp_code.append(' ' * 4 * indent_level + '{')
              indent_level += 1
          elif stripped_line.startswith('return '):
              csharp_code.append(' ' * 4 * indent_level + f'return {stripped_line[7:]};')
          elif stripped_line == '':
              continue
          else:
              csharp_code.append(' ' * 4 * indent_level + stripped_line)
      while indent_level > 0:
          indent_level -= 1
          csharp_code.append(' ' * 4 * indent_level + '}')
      return '\n'.join(csharp_code)