using static System.Console;
using System.IO;
public class Program {
public static void Main() => WriteLine(Directory.GetParent("/Pasta1/Pasta2"));
}