import sys sys.setrecursionlimit(1000000000) # # Solution Template for Pairing Cards # # Australian Informatics Olympiad 2025 # # This file is provided to assist with reading of input and writing of output # for the problem. You may modify this file however you wish, or # you may choose not to use this file at all. # # N is the number of cards. N = 0 # D and S are the allowed difference and sum of paired cards. D = 0 S = 0 # A contains the values on the cards. Note that the list starts from 0, and so # the values are A[0] to A[N-1]. A = [] # Read the values of N, D, S, and the values on the cards. N, D, S = map(int, input().strip().split()) A = list(map(int, input().strip().split())) # TODO: This is where you should compute your solution. You should output YES # or NO depending on whether it is possible to divide the cards into N/2 valid # pairs. An example of how to output YES is shown below. print("YES")