Gondola Replacement

No attempts yetTime limit1sMemory limit256 MB

Problem

A gondola line has nn cars numbered 11 to nn moving on a circular track. After car ii passes the station, car i+1i+1 passes next (and car 11 follows car nn). A broken car is replaced at the same spot by spare cars numbered n+1n+1, n+2n+2, and so on in order. A gondola sequence lists the nn car numbers seen at the station starting from some moment. A replacement sequence lists the original car numbers that broke, in breakdown order. Given a valid gondola sequence, output one replacement sequence that could produce it.

Input

The first line contains nn. The second line contains the gondola sequence of length nn.

Output

Print the length ll of the replacement sequence. If l>0l>0, print the sequence on the same line separated by spaces.

Constraints

  • 2n100,0002 \leq n \leq 100{,}000
  • The input sequence is always a valid gondola sequence.