#K75917. Distinct Pairs Sum
Distinct Pairs Sum
Distinct Pairs Sum
Given an integer N, your task is to count the number of distinct pairs of positive integers (a, b) such that a + b = N. Note that the pair (a, b) is considered the same as (b, a), so each pair is counted only once.
If N < 3, there are no such pairs since both a and b must be at least 1. For N ≥ 3, the number of distinct pairs is given by the formula:
$$\left\lfloor \frac{N-1}{2} \right\rfloor$$
Your program should read the input from stdin and output the answer to stdout.
inputFormat
The input consists of a single integer N
(1 ≤ N ≤ 109) provided via standard input.
outputFormat
Output a single integer representing the number of distinct pairs (a, b) such that a + b = N.
## sample5
2
</p>