P11045 [CodeChef] cd101
NOI
题目描述

Three dinos go on a camping trip. There they decide to play a game. They mark distances of 1 km each on the ground up to 100 km i.e. 1, 2, 3...100. They can sit only on these 100 spots, with each one at a different spot. In one move, one of the outer dinos can hop into a spot between the other two.
Help them maximise their duration of play.

Input
Three numbers(integers), l, m and n (0 < l < m < n < 100), the starting spots of the dinosaurs.

Output
Output the largest number of jumps the dinosaurs can make in all.

Example

Input
4 5 7
Output
1
Input
5 6 11
Output
4

输入格式

见题面

输出格式

见题面

样例输入
4 5 7
样例输出
1