#include<bits/stdc++.h>
using namespace std;
int a[3];
int main(){
cin>>a[0]>>a[1]>>a[2];
sort(a,a+3);
if(a[0]==a[1]-1&&a[1]==a[2]-1)
cout<<0<<endl;
else if(a[1]-a[0]==2||a[2]-a[1]==2)
cout<<1<<endl;
else
cout<<2<<endl;
int m1=a[1]-a[0]-1;
int m2=a[2]-a[1]-1;
cout<<max(m1,m2)<<endl;
return 0;
}
11-09
1万+
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
02-04
3万+
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
02-15
1万+
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
08-12
497
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
12-30