using System;
public class Program
{
public static void Main()
Console.WriteLine("Hello World");
}
static string? DoSomething(IList<string?> messages)
return messages switch
[] => null,
[{ } first] => first,
_ => throw new Exception("urgh")
};