You are given a permutation of .
You may choose two integers with and reverse the contiguous subsequence .
You must perform this operation exactly once.
Find the minimum possible number of integers () such that after the operation.
The input is given in the following format.
Print the minimum possible number of integers such that after the operation.