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<bits/stdc++.h>
using namespace std;
using ll = long long;
using P = pair<int,int>;
#define enld '\n'
#define rep(i,n) for(int i=0; i<(n); i++)
#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")
#pragma GCC optimize("Ofast")
constexpr ll INF = 1e18;
constexpr int inf = 1e9;
constexpr ll mod = 1000000007;
constexpr ll mod2 = 998244353;
const double PI = 3.1415926535897932384626433832795028841971;
const int dx[6] = {1, 0, -1, 0,1,1};
const int dy[6] = {0, 1, 0, -1,1,-1};
template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return 1; } return 0; }
template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return 1; } return 0; }
// ---------------------------------------------------------------------------

int main(){
    ios::sync_with_stdio(false);
    cin.tie(nullptr);
    int sum = 0;
    int mn = inf;
    for(int i=0; i<3; i++){
        int a;
        cin >> a;
        chmin(mn,a);
    }
    sum += mn;
    mn = inf;
    for(int i=0; i<2; i++){
        int a;
        cin >> a;
        chmin(mn,a);
    }
    sum += mn;
    cout << sum - 50 << enld;
    return 0;
}

C++: #include<stdio.h>
 
int main(void)
{
  int pasuta[4];
  int nomimono[3];
  int i,j,mini1,mini2;

  mini1=0;
  mini2=0;
  for(i=1;i<=3;i++)
    {
      scanf("%d",&pasuta[i]);
    }
  for(i=1;i<=2;i++)
    {
      scanf("%d",&nomimono[i]);
    }

  mini1=pasuta[1];
  for(i=2;i<=3;i++)
    {
      if(mini1>pasuta[i])
	{
	  mini1=pasuta[i];
	}
    }

  mini2=nomimono[1];
  if(mini2>nomimono[2])
    {
      mini2=nomimono[2];
    }

  j=(mini1+mini2)-50;

  printf("%d\n",j);
    return 0;
}

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

int main() {
	int p = numeric_limits<int>::max(), j = numeric_limits<int>::max();
	int a;
	for (int i = 0; i < 3; i++) {
		cin >> a;
		p = min(p, a);
	}
	for (int i = 0; i < 2; i++) {
		cin >> a;
		j = min(j, a);
	}
	cout << p + j - 50 << endl;
}

C++: #include<iostream>
#include<algorithm>
using namespace std;
int main(){
	int pst1,pst2,pst3,ju1,ju2;
	int mpst,mju;
	cin>>pst1>>pst2>>pst3>>ju1>>ju2;

	mpst=min(pst1,pst2);
	mpst=min(mpst,pst3);
	mju =min(ju1,ju2);
	cout<<mpst+mju-50<<endl;
}

C++: #include<stdio.h>
#define M(a,b) (a<b?a:b)
int main()
{
	int a,b,c,d,e;
	scanf("%d%d%d%d%d",&a,&b,&c,&d,&e);
	printf("%d\n",M(M(a,b),c)+M(d,e)-50);
	return 0;
}

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

C++: a,b,c,d;main(e){scanf("%d%d%d%d%d",&a,&b,&c,&d,&e);a=!printf("%d\n",d<e?d:e+fmin(a>b?a:b,c));}

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>
#include <algorithm>

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

using namespace std;

int x[5];

int main(){
	rep(i, 5){
		cin >> x[i];
	}
	cout << *min_element(x, x + 3) + min(x[3], x[4]) - 50 << endl;
	return 0;
}

C++: #include <iostream>
#include <vector>
#include <algorithm>
#include <set>
#include <queue>
#include <stack>
#include <string>
#include <map>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <cmath>

#define rep(i, n) for(int i = 0; i < n; i ++)
#define ALL(T) T.begin(), T.end()
#define mp make_pair
#define pb push_back

using namespace std;

typedef pair<int, int> pii;
typedef unsigned long long ull;
typedef vector<int> vi;
typedef vector<string> vs;

const int INF = 1 << 24;
const int p[2] = {3, 2};

int main(void){
    int s = -50;
    rep(i, 2){
        int in, res = INF;
        rep(i, 3) cin >> in, res = min(in, res);
        s += res;
    }
    cout << s << endl;

    return 0;
}

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

int pasta[3], juice[2], m = INT_MAX;

int main(void){
  for(int i = 0; i < 3; i++) cin >> pasta[i];
  for(int i = 0; i < 2; i++) cin >> juice[i];
  for(int i = 0; i < 3; i++){
    for(int j = 0; j < 2; j++){
      int n = pasta[i] + juice[j] - 50;
      if(n < m) m = n;
    }
  }
  cout << m << endl;
  return 0;
}

C++: #include <bits/stdc++.h>
#define INFTY 2001

int main()
{
    int tmp;
    int minv = INFTY;
    int sum = 0;
    for (int i = 0; i < 3; i++) {
        std::scanf("%d", &tmp);
        minv = std::min(minv, tmp);
    }
    sum = minv;
    minv = INFTY;
    for (int i = 0; i < 2; i++) {
        std::scanf("%d", &tmp);
        minv = std::min(minv, tmp);
    }
    sum += minv;
    std::cout << sum - 50 << std::endl;


    return 0;
}

C++: //============================================================================
// Name        : AOL.cpp
// Author      : Akari Fujii
// Version     :
// Copyright   : Your copyright notice
// Description : Hello World in C++, Ansi-style
//============================================================================

#include <iostream>
using namespace std;

int main() {
	int a,b,c,d,e,p,j;
	cin>>a>>b>>c>>d>>e;
	p=a;
	if(p > b)p=b;
	if(p > c)p=c;
    j=d;
	if(d > e)j=e;
    cout<< p+j-50<<endl;
    return 0;
    }

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

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