How do I compare both numbers are equally close to 10 and display that number?