#include <bits/stdc++.h>
using namespace std;

int main (void){
    vector<int> hoge(3);
    cin >> hoge[0] >> hoge[1] >> hoge[2];
    sort(hoge.begin(), hoge.end());
    cout << hoge[1] + hoge[2] << endl;
}
#include<bits/stdc++.h>
using namespace std;
#define gc() (p1 == p2 ? (p2 = buf + fread(p1 = buf, 1, 1 << 20, stdin), p1 == p2 ? EOF : *p1++) : *p1++)
#define read() ({ register int x = 0, f = 1; register char c = gc(); while(c < '0' || c > '9') { if (c == '-') f = -1; c = gc();} while(c >= '0' && c <= '9') x = x * 10 + (c & 15), c = gc(); f * x; })
char buf[1 << 20], *p1, *p2;
int main(){
	int n = read(),a = read(),b = read();
	cout<<n-a+b<<endl;
	return 0;
}
