#include<bits/stdc++.h>

using namespace std;

#define pb push_back
#define mp make_pair
#define s(x) x.size()
#define endl '\n'
#define r(n) ll n; cin>>n;
#define vl vector<ll>
#define all(x) (x).begin(),(x).end()
#define fk(i,start,end) for(ll i=start;i<ll(end);i++)
typedef long long int ll;
const ll MOD = 1e9 + 7;
string A="YES";
string B="NO";

void solution()
{
    std::vector<ll> v(3);
    fk(i,0,3)
    {
        cin>>v[i];
    }
    sort(all(v));
    cout<<v[1]+v[2];

}

int32_t main()
{
    ios_base::sync_with_stdio(0);
    cin.tie(0);
    cout.tie(0);

    #ifndef ONLINE_JUDGE
    freopen("input1.txt", "r", stdin);
    freopen("output1.txt", "w", stdout);
    #endif

    solution();
    return 0;
}
#include <bits/stdc++.h>
using namespace std;

int main() {
  int N;
  cin>>N;
  
  int sam =0;
  int i=1;
  
  while(sam < N){
    sam += i;
    i++;
  }
  cout<< i-1 <<endl;
}
