F. Build the Non-Cactus
time limit per test
1 second
memory limit per test
512 megabytes
input
standard input
output
standard output

In graph theory, a cactus is a connected undirected graph in which any two simple cycles have at most one vertex in common.

Given an integer $$$n$$$, build a connected graph with $$$n$$$ vertices that is not a cactus. Note that your graph can't have self-loops or multiple edges. The number of edges in your graph should be minimum possible.

Input

The input consists of a single integer $$$n$$$ ($$$2 \le n \le 1000$$$).

Output

If there is no connected graph of $$$n$$$ vertices without self-loops and multiple edges that is not a cactus, print -1 in the only line of the output. Otherwise, first print positive integer $$$m$$$ — the number of edges in your graph. Then print $$$m$$$ lines, each containing two integers — edges of the resulting graph. Use consecutive integers $$$1, 2, \ldots, n$$$ to enumerate the vertices of the graph.

If there are more than solutions with minimum number of edges, print any of them.

Example
Input
3
Output
-1