Go: package main

import (
	"bufio"
	"fmt"
	"os"
	"strconv"
)

var sc = bufio.NewScanner(os.Stdin)

func nextInt() int {
	sc.Scan()
	n, _ := strconv.Atoi(sc.Text())
	return n
}

func main() {
	sc.Split(bufio.ScanWords)

	a, b, c, d, e := nextInt(), nextInt(), nextInt(), nextInt(), nextInt()
	x := a
	if b < x {
		x = b
	}
	if c < x {
		x = c
	}
	y := d
	if e < y {
		y = e
	}

	fmt.Println(x + y - 50)
}

C++: #include <iostream>
using namespace std;

int main()
{
	int p[3];
	int j[2];
	int pp,jj;
	
	cin>>p[0]>>p[1]>>p[2]>>j[0]>>j[1];
	if(p[0]<p[1]&&p[0]<p[2]){
		pp=p[0];
	}
	if(p[1]<p[0]&&p[1]<p[2]){
		pp=p[1];
	}
	if(p[2]<p[0]&&p[2]<p[1]){
		pp=p[2];
	}
	if(j[0]<j[1]){
		jj=j[1];
	}
	else{
		jj=j[0];
	}
	
	cout<<endl<<pp+jj-50<<endl;
	return 0;
}

C++: #include<iostream>
using namespace std;

int main(){
	
	int pasta[3], juice[2];
	
	for(int i=0; i<3; i++){
		cin >> pasta[i];
	}
	for(int i=0; i<2; i++){
		cin >> juice[i];
	}
	
	sort(pasta, pasta+3);
	sort(juice, juice+2);
	
	cout << pasta[0] + juice[0] - 50 << endl;
	
	return 0;

}

C++: #include <iostream>
#include <algorithm>
using namespace std;
int main(){
	int a,b,c,d,e;
	cin>>a>>b>>c>>d>>e;
	if(a>b)swap(a,b);
	if(b>c)swap(b,c);
	if(a>b)swap(a,b);
	if(d>e)swap(d,e);
	cout<<a+d-50<<endl;
	return 0;
	}

C++: #include <string>
#include <vector>
#include<iostream>
#include<algorithm>
#include<cstdio>
#include<cstdlib>
#include<sstream>
#include<functional>
#include<map>
#include<set>
#include<cmath>

using namespace std;

int main(){

	int a[5];

	for(int i=0;i<5;i++) cin >> a[i];

	int m=5000;
	for(int i=0;i<3;i++){
	for(int j=3;j<5;j++){
	if(m>a[i]+a[j]) m=a[i]+a[j];

	}
	}

	cout << m-50 << endl;

	return 0;
}

C++: #include "bits/stdc++.h"

using namespace std;

const char en = '\n';
using  ll =          long long;
using ull = unsigned long long;
#define REP(i  ,n) for(int i=0;i<n;i++)
#define FOR(i,s,g) for(int i=s;i<g;i++)
const int INFL = 8108931871919114514;
const int INF  =          1919114514;

int main(){
	ios::sync_with_stdio(false);cin.tie();

	int pasta=INF,juice=INF,buf;
	REP(i, 3){
		cin>>buf;
		pasta=min(pasta,buf);
	}
	REP(i, 2){
		cin>>buf;
		juice=min(juice,buf);
	}

	cout<<pasta+juice-50<<en;
	return 0;
}

C++: #include <iostream>
#include <algorithm>
using namespace std;

int main() {
	int a, b, c, d, e, q, w;
	cin >> a >> b >> c >> d >> e;
	q = min({ a,b,c });
	w = min({ d,e });
	cout << q + w - 50 << endl;
}

C++: #include<iostream>
using namespace std;
int main(){
	int i, a, ans, min = 10000;
	for (i = 0; i < 3; i++){
		cin >> a;
		if (min > a){
			min = a;
		}
	}
	ans = min - 50;
	min = 10000;
	for (i = 0; i < 2; i++){
		cin >> a;
		if (min > a){
			min = a;
		}
	}
	ans = ans + min;
	cout << ans;
	return 0;
}

C++: #include "bits/stdc++.h"
using namespace std;

/* macro */
#define rep(i,a,b) for(int i=a;i<b;i++)
#define revrep(i,a,b) for(int i = a; i > b; i--)
#define int long long
#define exist(s,e) ((s).find(e)!=(s).end())
#define all(v) (v).begin(), (v).end()
#define each(s,itr) for(auto (itr) = s.begin(); (itr) != s.end(); (itr)++)
#define sum(v) accumulate(all(v), (0LL))
#define isin(a, b, c) (b <= a && a <= c)
#define println cout << "\n";
#define sz(v) (int)v.size()


/* alias */
template<class T> using vec = vector<T>;
typedef vector<int> vi;
typedef pair<int, int> pi;
typedef tuple<int, int, int> ti;
typedef map<int, int> mi;
typedef set<int> si;


/* constant */
const int inf = 1LL << 62;
const int mod = 1e9 + 7;
const int dx[8]={1,0,-1,0,-1,1,-1,1};
const int dy[8]={0,1,0,-1,-1,-1,1,1};
const string alphabet = "abcdefghijklmnopqrstuvwxyz";

/* io_method */
int input(){int tmp;cin >> tmp;return tmp;}
string raw_input(){string tmp;cin >> tmp;return tmp;}
template<class T> void printx(T n){cout << n;}
template<class T, class U> void printx(pair<T, U> p){cout << "(" << p.first << "," << p.second << ")";}
template<class T, class U, class V> void printx(tuple<T, U, V> t){cout << "{" << get<0>(t) << "," << get<1>(t) <<"," << get<2>(t) << "}" << endl;}
template<class T> void printx(vector<T> v){cout << "{";rep(i,0,v.size()){printx(v[i]);if(i != v.size()-1)printx(",");}cout << "}";}
template<class T> void print(T n){printx(n);cout << endl;}
template<class T> void print(set<T> s){cout << "{";each(s, e){if(e != s.begin()) printx(",");printx(*e);}cout << "}" << endl;}
template<class T, class U> void print(map<T, U> mp){cout << "{";each(mp, e){cout << "(" << e -> first << "," << e -> second << ")";}cout << "}" << endl;}
template<class T> void printans(vec<T> v){rep(i,0,sz(v)){cout << v[i] << (i == sz(v) - 1 ? "" : " ");}cout << endl;}


/* general_method */
template<class T>bool chmax(T &a, const T &b) { if (a<b) { a=b; return 1; } return 0; }
template<class T>bool chmin(T &a, const T &b) { if (b<a) { a=b; return 1; } return 0; }
template<class T>T cut(T &a, int l, int r){return T(a.begin()+l, a.begin()+r);}

/* main */

int a, b, c, d, e;
void in(){
    cin >> a >> b >> c >> d >> e;
}

void solve(){

    print(min({a, b, c}) + min(d, e) - 50);


}

signed main(){

    cin.tie(0);
    ios::sync_with_stdio(false);
    in();
    solve();
    
}

C++: #include <iostream>
using namespace std;
int main(void){
    // Your code here!
    int a,b,c,d,e;
    int counter=0;
    cin>>a>>b>>c>>d>>e;
    counter=a;
    if(counter>=b)
    {
        counter=b;
    }
    if(counter>=c)
    {
        counter=c;
    }
    if(d<=e)
    {
        counter=counter+d;
    }
    if(d>e)
    {
        counter=counter+e;
    }
    cout<<counter-50<<endl;
    return 0;
}

C++: #include<cstdio>
#include<functional>
#include<algorithm>
using namespace std;
int main(void)
{
	int a[3],b[2],i,x;
	for(i=0;i<3;i++){
		scanf("%d",&a[i]);
	}
	for(i=0;i<2;i++){
		scanf("%d",&b[i]);
	}
	sort(a,a+3);
	sort(b,b+2);
	x=a[0]+b[0]-50;
	printf("%d\n",x);
	return 0;
}

C++: #include <iostream>
#include <algorithm>
#include <string>
#include <vector>
#include <map>
#include <sstream>
#include <functional>
#include <numeric>
#include <cmath>
#include <cstring>
#include <queue>

using namespace std;
int n;

const int INF = 1 << 29;

int main(void)
{
	int pasta = INF;
	for (int i = 0; i < 3; i++)
	{
		int tmp;
		cin >> tmp;
		pasta = min(tmp, pasta);
	}
	int juice = INF;
	for (int i = 0; i < 2; i++)
	{
		int tmp;
		cin >> tmp;
		juice = min(tmp, juice);
	}
	cout << pasta + juice - 50;
	return 0;
}

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

int main(){
    int a, b, c, d, e;
    scanf("%d%d%d%d%d", &a, &b, &c, &d, &e);
    printf("%d\n", min(a, min(b, c)) + min(d, e) - 50);
    return 0;
}

C++: #include <iostream>
#include <algorithm>
using namespace std;
int main(void){
    int a,b,c,d,e;
    int A,B;
    
    cin >>a>>b>>c>>d>>e;
    
    A=min(a,min(b,c));
    B=min(d,e);
    
    cout <<A+B-50<<endl;
}

C++: #include<iostream>
#include<string>
#include<algorithm>
#include<stack>
#include<queue>
#include<set>
using namespace std;
int main()
{
	int a, b, c, d, e,f,g,h, i, j, k, l, m, n, o, p, q, r,s,t,u;
	cin >> a;
	cin >> b;
	cin >> c;
	cin >> d;
	cin >> e;
	a = min(a, b);
	a = min(a, c);
	d = min(d, e);
	e = a + d;
	cout << e-50 << endl;
	return 0;
}

C++: #include<iostream>
using namespace std;
int main(){

	int a[3], b[2];
	for(int i=0;i<3;i++) cin>>a[i];
	int mn1 = a[0];
	for(int j=0;j<2;j++) cin>>b[j];
	int mn2 = b[0];
	for(int i=0;i<3;i++){
		mn1 = min(mn1, a[i]);
		mn2 = min(mn2, b[i]);
	}
	cout<<mn1 + mn2 - 50<<endl;
	return 0;
}