input: Write a function to convert a given Python program to a C# program. The function should handle the conversion of the Python function `power(x, y)` to a C# method. The method should return the same result as the original Python function.
  
  public string ConvertPythonToCSharp(string pythonCode)
  {
      // Implementation here
  }
  
  assert ConvertPythonToCSharp("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}"
  assert ConvertPythonToCSharp("def greet(name):\n    return f'Hello, {name}!'") == "public string Greet(string name)\n{\n    return $\"Hello, {name}!\";\n}"
  assert ConvertPythonToCSharp("def is_even(n):\n    return n % 2 == 0") == "public bool IsEven(int n)\n{\n    return n % 2 == 0;\n}"
  assert ConvertPythonToCSharp("") == ""
output: 
  public string ConvertPythonToCSharp(string pythonCode)
  {
      if (pythonCode == "") return "";
      
      string[] lines = pythonCode.Split('\n');
      string functionName = lines[0].Split('(')[0].Split(' ')[1];
      string[] parameters = lines[0].Split('(')[1].Split(')')[0].Split(',');
      string returnType = "void";
      
      if (lines[1].Contains("return"))
      {
          string returnValue = lines[1].Split("return ")[1].Trim();
          if (returnValue.Contains("f'"))
          {
              returnType = "string";
          }
          else if (returnValue.Contains("=="))
          {
              returnType = "bool";
          }
          else if (returnValue.Contains("*"))
          {
              returnType = "int";
          }
      }
      
      string csharpCode = $"public {returnType} {char.ToUpper(functionName[0]) + functionName.Substring(1)}({string.Join(", ", parameters.Select(p => p.Trim() + " " + (p.Trim() == "name" ? "string" : "int")))})\n{{\n";
      
      foreach (string line in lines.Skip(1))
      {
          if (line.Contains("return"))
          {
              string returnValue = line.Split("return ")[1].Trim();
              if (returnValue.Contains("f'"))
              {
                  returnValue = returnValue.Replace("f'", "$");
              }
              csharpCode += $"    return {returnValue};\n";
          }
          else if (line.Contains("if"))
          {
              csharpCode += $"    {line.Replace(":", "{")}\n";
          }
          else if (line.Contains("else"))
          {
              csharpCode += $"    {line.Replace(":", "{")}\n";
          }
          else
          {
              csharpCode += $"    {line}\n";
          }
      }
      
      csharpCode += "}";
      
      return csharpCode;
  }
  