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],j[2],t,p2,j2;
	for(int i=0;i<3;i++)
		cin >>p[i];
	for(int i=0;i<2;i++)
		cin >>j[i];
	

	for(int i=0;i<3;i++){
		for(int k=0;k<2;k++)
		if(p[k]>p[k+1]){
			t=p[k];
			p[k]=p[k+1];
			p[k+1]=t;
			
			}
		}
	p2=p[0];

	if(j[0]>j[1])
		j2=j[1];
	if(j[0]<j[1])
		j2=j[0];
	cout <<j2+p2-50 <<endl;


	return 0;
}

C++: #include <stdio.h>

#define DNUM 2
#define PNUM 3

int main(void){
	int minP=2000, minD=2000;
	int tmp;
	
	for (int i=0; i<PNUM; i++){
		scanf("%d", &tmp);
		if (tmp < minP) minP = tmp;
	}
	for (int i=0; i<DNUM; i++){
		scanf("%d", &tmp);
		if (tmp < minD) minD = tmp;
	}
	
	printf("%d\n", minD+minP-50);
	
	return 0;
}

C++: #include<iostream>
#include<algorithm>
using namespace std;
int main() {
	int p, z, a;
	p = 9990;
	z = 9990;
	for (int i = 1; i <= 3; i++) {
		cin >> a;
		p = min(a, p);
	}
	for (int i = 1; i <= 2; i++) {
		cin >> a;
		z = min(a, z);
	}
	cout << z + p - 50 << endl;
}

C++: #include <iostream>
#include <algorithm>

using namespace std;

int main(void){
  
  int p1,p2,p3,j1,j2,P;
  
  cin >> p1 >> p2 >> p3 >> j1 >> j2;

  if( p1 >= p2 && p2 >= p3 ) P = p3; 
  else if( p1 >= p3 && p3 >= p2 ) P = p2; 
  else if( p2 >= p1 && p1 >= p3 ) P = p3; 
  else if( p2 >= p3 && p3 >= p1 ) P = p1;
  else if( p3 >= p1 && p1 >= p2 ) P = p2;
  else if( p3 >= p2 && p2 >= p1 ) P = p1;


  int J = min(j1,j2);

  cout << P + J - 50 << endl;

  return 0;
}

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

#define rep(i,n) for(int i=0;i<(n);i++)
#define pb push_back
typedef vector<int>vint;
typedef pair<int,int>pint;

int get(int n){
    int ret=114514;
    rep(i,n){
        int a;cin>>a;
        ret=min(ret,a);
    }
    return ret;
}


int main(){
    int x=get(3);
    int y=get(2);
    cout<<x+y<<endl;
    return 0;
}

C++: #include<cstdio>
#include<algorithm>
#include<functional>

using namespace std;

int main(void)
{
	int pa[3],ju[2];
	int x,y,i;
	for(i=0;i<3;i++){
		scanf("%d",&pa[i]);
	}
	for(i=0;i<2;i++){
		scanf("%d",&ju[i]);
	}
	sort(pa,pa+3);
	sort(ju,ju+2);
	x=pa[0]+ju[0]-50;
	printf("%d\n",x);
	return 0;
}

C++: #define _USE_MATH_DEFINES
#define INF 100000000
#include <iostream>
#include <sstream>
#include <cmath>
#include <cstdlib>
#include <algorithm>
#include <queue>
#include <stack>
#include <limits>
#include <map>
#include <string>
#include <cstring>
#include <set>
#include <deque>
#include <bitset>
#include <list>

using namespace std;

typedef long long ll;
typedef pair <int,int> P;

static const double EPS = 1e-8;

int tx[] = {1,0};
int ty[] = {0,1};

int main(){
	int p[3];
	int ju[2];
	for(int i=0;i<3;i++){
		scanf("%d",p+i);
	}

	for(int i=0;i<2;i++){
		scanf("%d",ju+i);
	}

	int res = INF;
	for(int i=0;i<3;i++){
		for(int j=0;j<2;j++){
			res = min(res,p[i]+ju[j] -50);
		}
	}
	printf("%d\n",res);
}

C++: #include <stdio.h>

main()
{
	int a,b,c,d,e;
	scanf("%d",&a);
	scanf("%d",&b);
	scanf("%d",&c);
	scanf("%d",&d);
	scanf("%d",&e);
	int m,n;
	if (a<b)
		if (a>c) m = c;
		else     m = a;
	else
		if (b>c) m = c;
		else	 m = b;
	if (d<e) n = d;
	else	 n = e;
	int S;
	S = m + n - 50;
	printf("%d",S);
}

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

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

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

int main(){
int a,b,A=9999,B=9999;
for(int i=0;i<3;i++)cin>>a,A=min(A,a);
for(int i=0;i<2;i++)cin>>b,B=min(B,b);
cout<<A+B-50<<endl;
}

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

C++: #include <iostream>
#include <algorithm>

using namespace std;

int main() {
    int p1, p2, p3;
    cin >> p1 >> p2 >> p3;
    int j1, j2;
    cin >> j1 >> j2;

    int min_p = min(p1, min(p2, p3));
    int min_j = min(j1, j2);
    cout << min_p+min_j-50 << endl;
    return 0;
}

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

int main(){
 int x;
 int y;
 int z;
 int a;
 int b;
 cin>>x>>y>>z>>a>>b;

 int p = x+a-50;
 int q = x+b-50;
 int r = y+a-50;
 int s = y+b-50;
 int t = z+a-50;
 int u = z+b-50;
   int min;
   int k={p,q,r,s,t,u};
   for(int i=0;i<k;i++){
    min = min(min,k[i]);
   }
 cout<<min<<endl;
 return 0;
}

C++: #include <iostream>


using namespace std;

int main(){
	int p1;
	int p2;
	int p3;
	int j1;
	int j2;
	cin >> p1 >> p2 >> p3 >> j1 >> j2;
	int p = min({ p1, min(p2, p3) });
	int j = min({ j1, j2 });
	cout << p + j - 50<< endl;

	return 0;
}

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

int main(){
int a,b,c,d,e,f;
cin>>a>>b>>c>>d>>e;
if(a>b){
if(b>c){
f=c;
}
if(b<c){
f=b;
}
}
else{
if(a<c){
f=a;
}
if(a>c){
f=c;
}
}

if(d<e){
cout<<f+d-50;
}

if(d>e){
cout<<f+e-50;
}

return 0;
}

C++: #include <iostream>

using namespace std;

int main(){

	int pa_1 , pa_2 , pa_3;
	int juice_1 , juice_2;
	int ans_pa , ans_j;

	cin >> pa_1 >> pa_2 >> pa_3;
	cin >> juice_1 >> juice_2;

	if(pa_1 < pa_2 && pa_1 < pa_3){
		ans_pa = pa_1;

	}else if(pa_2 < pa_1 && pa_2 < pa_3){
		ans_pa = pa_2;

	}else if(pa_3 < pa_1 && pa_3 < pa_2){
		ans_pa = pa_3;

	}

	if(juice_1 < juice_2){
		ans_j = juice_1;
	
	}else if(juice_2 < juice_1){
		ans_j = juice_2;

	}

	cout << ans_pa + ans_j - 50 << endl;

	return 0;
}

C++: #include <iostream>
#include <fstream>
#include <typeinfo>
#include <vector>
#include <cmath>
#include <set>
#include <map>
#include <string>
#include <algorithm>
#include <cstdio>
#include <queue>
#include <iomanip>
#include <cctype>
#define syosu(x) fixed<<setprecision(x)
using namespace std;
typedef long long ll;
typedef pair<ll,ll> P;
typedef pair<double,double> pdd;
typedef vector<int> vi;
typedef vector<vi> vvi;
typedef vector<char> vc;
typedef vector<vc> vvc;
typedef vector<bool> vb;
typedef vector<vb> vvb;
typedef vector<P> vp;
typedef vector<vp> vvp;
typedef pair<int,P> pip;
typedef vector<pip> vip;
const int inf=1<<30;
const ll INF=1ll<<50;
const double pi=acos(-1);
const double eps=1e-8;
const vi emp;

int ans=-50;

int main(){
	int m=inf;
	for(int i=0;i<3;i++){
		int t;
		cin>>t;
		m=min(m,t);
	}
	ans+=m;
	m=inf;
	for(int i=0;i<2;i++){
		int t;
		cin>>t;
		m=min(m,t);
	}
	ans+=m;
	cout<<ans<<endl;
}

C++: #include<cstdio>
#include<algorithm>
#include<vector>
#include<string>
#include<iostream>

using namespace std;

#define rep(i,n) for(int i=0;i<int(n);i++)
#define reps(i,n) for(int i=1;i<=int(n);i++)

int main(){
	int mini[2]={3333,3333};
	for(int i=0;i<5;i++){
		int a;
		cin>>a;
		mini[i/3]=min(mini[i/3],a);
	}
	
	printf("%d\n",mini[0]+mini[1]-50);
}

C++: #include<iostream>
#include<vector>
#include<algorithm>
using namespace std;
int main() {
	vector<int>pasta(3), juce(2);
	for (int i = 0; i < 3; i++)cin >> pasta[i];
	for (int i = 0; i < 2; i++)cin >> juce[i];
	cout << *min_element(pasta.begin(), pasta.end()) + min(juce[0], juce[1]) - 50 << endl;
	return 0;
}

C++: #include<algorithm>
#include<iostream>

int main()
{
	int a, b, c, d, e;
	std::cin >> a >> b >> c >> d >> e;

	std::cout << std::min( a, std::min( b, c ) ) + std::min( d, e ) - 50 << std::endl;

	return 0;
}

C++: #include<iostream>
#include<stdio.h>
#include<algorithm>
using namespace std;
int main()
{
	int i, p, j,pg=20000,pj=20000;
	for (i = 0; i < 3; i++)
	{
		cin >> p;
		pg = min(p, pg);
	}
	for (i = 0; i < 2; i++)
	{
		cin >> j;
		pj = min(j, pj);
	}
	cout << pj + pg - 50 << endl;
	return 0;
}