The school spent the tuition money on every building in Heukseok-dong and made the campus larger. You run the company that operates the shuttle buses, so you have to plan a new route inside the enlarged campus.
The only road built on the campus is one straight two-lane road. There is no other road. The road carries n stops.
To design the route you wrote down the position of each of the n stops as an integer coordinate A1,A2,…,An.
Anyone who moves from one stop to another has to take the bus. You want a cheaper route, but if you remove too many stops the students get angry and you lose your job. So you decided to merge only the two closest stops into one.
Write a program that finds the smallest distance between two of the n stops and counts the pairs of stops that are exactly that far apart.