class Program { static void Main(string[] args) { string[] input = Console.ReadLine()!.Split(' '); int holiday1 = int.Parse(input[0]); int holiday2 = int.Parse(input[1]); int now = int.Parse(input[2]); int count = 0; for (int i = 0; i < now; i++) { if (i != holiday1 || i != holiday2) { count++; } } Console.WriteLine(count - 1); } }