l=set(map(int,open("/dev/stdin").readlines())) print([a*(2020-a) for a in l if 2020-a in l])