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"
#include "climits"
#include "list"
#include "queue"
#include "stack"
#include "set"
#include "functional"
#include "algorithm"
#include "string"
#include "map"
#include "unordered_map"
#include "unordered_set"
#include "iomanip"
#include "cmath"
#include "random"
#include "bitset"
#include "cstdio"
#include "numeric"
#include "cassert"
#include "functional"
#include "ctime"

using namespace std;

constexpr long long int MOD = 1000000007;
//constexpr int MOD = 1000000007;
//constexpr int MOD = 998244353;
//constexpr long long int MOD = 998244353;
constexpr double EPS = 1e-8;

//int N, M, K, H, W, L, R;
long long int N, M, K, H, W, L, R;


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

	cin >> N >> M >> K >> L >> R;
	cout << min({ N,M,K }) + min(L, R) - 50 << endl;
	return 0;
}

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

using namespace std;

int main(){
	priority_queue<int,vector<int>,greater<int> > que;
	int ans = -50;
	int self;
	for(int i=0;i<3;i++){
		scanf("%d",&self);
		que.push(self);
	}
	ans += que.top();
	que.pop();que.pop();que.pop();
	for(int i=0;i<2;i++){
		scanf("%d",&self);
		que.push(self);
	}
	ans += que.top();
	printf("%d\n",ans);
}

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 k[6]={p,q,r,s,t,u};
    int mn=k[0];
   for(int i=0;i<6;i++){
    mn = min(mn,k[i]);
   }
 cout<<mn<<endl;
 return 0;
}

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

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

int main() {
	int a[3],b[2],daikin=0;
	for(int i=0;i<3;i++){
		cin>>a[i];
		for(int j=0;j<2;j++){
			cin>>b[j];
			if(a[i]+b[j]<daikin){
				daikin=a[i]+b[j];
			}
		}
	}cout<<daikin<<endl;
	return 0;
}

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

int main() {
  int a, p, j;
  p = j = 1<<29;
  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;
  return 0;
}

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,B,C})+min(D,E))-50)<<endl;
}

C++: #include <iostream>
int main(){
	int p[3], j[2];
	int pmin = 2000, jmin = 2000;
	for (int i = 0; 1 < 3; i++) {
		std::cin >> p[i];
		if (p[i] < 2000) {
			pmin = p[i];
		}
	}
	for (int i = 0; 1 < 2; i++) {
		std::cin >> j[i];
		if (j[i] < 2000) {
			jmin = j[i];
		}
	}
	std::cout << jmin + pmin - 50 << std::endl;

	return 0;
}

C++: #include <stdio.h>
int main(){
int a,b,temp;
scanf("%d",&a);
scanf("%d",&temp);
if(temp<a)a=temp;
scanf("%d",&temp);
if(temp<a)a=temp;
b=a;
scanf("%d",&a);
scanf("%d",&temp);
if(temp<a)a=temp;
printf("%d\n",a+b-50);
}

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

int main(){

	int a,b,c,d,e,x,y;
	cin >> a >> b >> c >> d >> e;

	x = min( a , b );
	x = min( x , c );

	y = min( d , e );

	cout << x+y-50 << endl;

	return 0;
}

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

using namespace std;

set<int> Pasta, Juice;

int main() {
	int price;

	for (int i = 0; i < 3; ++i) {
		cin >> price;
		Pasta.insert(price);
	}
	for (int i = 0; i < 2; ++i) {
		cin >> price;
		Juice.insert(price);
	}
	cout << *Pasta.begin() + *Juice.begin() - 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;
  cout<<(min(min(a,b),c)+min(d,e)-50)<<endl;
  return 0;
}

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

using namespace std;

int main() {
  int pasta[3];
  int juice[2];
  cin >> pasta[0];
  cin >> pasta[1];
  cin >> pasta[2];
  cin >> juice[0];
  cin >> juice[1];
  int m = 100000;
  for (int i = 0; i < 3; i++) {
    for (int j = 0; j < 2; j++) {
      m = min(m, pasta[i] + juice[j]);
    }
  }
  cout << m - 50 << endl;

  return 0;
}

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

int main(){
int a=0;
int b=INT_MAX;
int c;
for(int d=0;d<3;d++){
	scanf("%d",&c);
	b=min(b,c);
}
a+=b;
b=INT_MAX;
for(int d=0;d<2;d++){
	scanf("%d",&c);
	b=min(b,c);
}
printf("%d\n",a+b-50);
}

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

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

C++: #include <iostream>
#include <algorithm>
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <string>
#include <cstring>
#include <vector>
#include <queue>
#include <stack>
#include <deque>
#include <map>
#include <set>
#include <bitset>
#include <limits>
typedef long long ll;
#define REP(i,n)   for(int i=0; i<(int)(n); ++i)
#define FOR(i,b,e) for(int i=(b); i<=(int)(e); ++i)

#define in cin
#define out cout
#define pb push_back
using namespace std;

int main(){
	int a[3], b[2];
	REP(i, 3)in >> a[i];
	REP(i, 2)in >> b[i];
	int ans = min(min(a[0],a[1]),a[2]) + min(b[0],b[1]) - 50;
	out << ans;
	return 0;

}

C++: #include<iostream>

using namespace std;

int main() {
  int a[3], b[2];
  cin >> a[0] >> a[1] >> a[2] >> b[0] >> b[1];
  cout << min(min(a[0], a[1]), a[2]) + min(b[0], b[1]) - 50 << endl;
  return 0;
}

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

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

	cout<<mn1+mn2-50<<endl;
    return 0;
}

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

int n, a = 2222, b = 2222;

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

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

int main()
{
    int pasuta[3];
    int dorink[2];

    for (int i = 0; i < 3; i++){
        cin >> pasuta[i];
    }
    for (int i = 0; i < 2; i++){
        cin >> dorink[i];
    }

    sort(pasuta, pasuta + 3);
    sort(dorink, dorink + 3);

    cout << (pasuta[0] + dorink[0]) - 50 << endl;

    return (0);
}

C++: #include <iostream>

using namespace std;

int main()
{
    int mm = 9999;
    int p[5];
    for( int i=0; i<5; ++i ) {
        cin >> p[i];
    }

    for( int i=0; i<3; ++i )
        for( int j=3; j<5; ++j )
            mm = min( mm, p[i] + p[j] - 50 );

    cout << mm << endl;
}

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

using namespace std;

int main(){
  int p[3], j[2];
  for(int i = 0; i < 3; i++)
    cin >> p[i];
  for(int i = 0; i < 2; i++)
    cin >> j[i];
  printf("%d\n", min(j[0], j[1]) + min(min(p[0], p[1]), p[2]) - 50);
  return 0;
}

C++: #include <iostream>
#include <algorithm>
#include <climits>
#include <string>
#include <vector>
#include <cmath>
using namespace std;

int A, B, C, D, E;
int main() {
  cin >> A >> B >> C >> D >> E;
  cout << min({A, B, C}) + min(D, E) - 50 << "\n";
  return 0;
}