using System;
public class Program
{
public static void Main()
var val = 3;
var res = (val > 0 ? val-1 : val) switch {
0 => A(),
1 => B(),
_ => throw new Exception()
};
Console.WriteLine(res);
}
static string A() { return "A"; }
static string B() { return "B"; }