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;

int main(){

int a,b,c,d,e,pasta,juice;

cin>>a>>b>>c>>d>>e;

pasta =a;

if(a>=b){
pasta=b;

if(b>=c){
pasta=c;}

}

juice=d;

if(d>=e)juice=e;

int sum=pasta+juice-50;

cout<<sum<<endl;

return 0;
}

C++: #include <iostream>
using namespace std;
int main(void){
    int P,A,S,j,u;
    cin>>P>>A>>S>>j>>u;
    
    int minP=min(P,A);
    int minA=min(minP,S);
    int minj=min(j,u);
    
    cout<<(minA+minj)-50<<endl;
}

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

int get(int n){
    int mi=INT_MAX;
    for(int i=0;i<n;i++){
        int a;cin>>a;
        mi=min(mi,a);
    }
    return mi;
}
int main(){
    int a=get(3);
    int b=get(2);

    cout<<a+b-50<<endl;
    return 0;
}

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

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

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

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

	cout << *min_element(pasta, pasta + 3) + *min_element(juice, juice + 2) - 50 << endl;

	return EXIT_SUCCESS;
}

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\n");
}

C++: #include<iostream>
#include<algorithm>
#include<cstdio>
#include<cmath>
#include<math.h>
#include<string>
#include<string.h>
#include<stack>
#include<queue>
#include<vector>
#include<utility>
#include<set>
#include<map>
#include<stdlib.h>
#include<iomanip>

using namespace std;

#define ll long long
#define ld long double
#define EPS 0.0000000001
#define INF 1e9
#define MOD 1000000007
#define rep(i,n) for(i=0;i<n;i++)
#define loop(i,a,n) for(i=a;i<n;i++)
#define all(in) in.begin(),in.end()
#define shosu(x) fixed<<setprecision(x)
#define first F
#define second S

typedef vector<int> vi;
typedef pair<int,int> pii;

int main(void) {
  int i,j;
  int n;
  int ans=0;
  int m=INF;
  rep(i,3){
    cin>>n;
    m=min(m,n);
  }
  ans+=m;
  m=INF;
  rep(i,2){
    cin>>n;
    m=min(m,n);
  }
  ans+=m;
  cout<<ans-50<<endl;
}

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

int main()
{
	//?????????
	int num1,num2,num3,num4,num5,num6;
	int sum;

	cin>>num1>>num2>>num3>>num4>>num5;
	if(num1>=num2){
		sum=num1;
		num1=num2;
		num2=sum;
	}
	if(num2>=num3){
		sum=num2;
		num2=num3;
		num3=sum;
	}
	if(num1>=num2){
		sum=num1;
		num1=num2;
		num2=sum;
	}
	if(num4>=num5){
		sum=num4;
		num4=num5;
		num5=sum;
	}
	num6=num1+num4-50;
	cout<<num6;
	cout<<"\n";
	return 0;
}

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

using namespace std;

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

C++: 
#include <stdio.h>
#include <algorithm>

using namespace std;

int main() {

	int pm = 114514, jm = 114514;

	for (int i = 0; i < 3; i++) {
		int p;
		scanf("%d", &p);
		pm = min(pm, p);
	}
	for (int i = 0; i < 2; i++) {
		int j;
		scanf("%d", &j);
		jm = min(jm, j);
	}

	printf("%d\n", pm + jm - 50);

	return 0;
}

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

int main(){
  int price[3];
  int price_j[2];

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

  int min,min_j;
  min = min_j = 3000;
  for(int i = 0; i < 3; i++){
    if(min > price[i] ){
      min = price[i];
    }
  }
  for(int i = 0; i < 2; i++){
    if(min_j > price_j[i]){
      min_j = price_j[i];
    }
  }

  cout << min + min_j - 50 << endl;
  return 0;
}

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

	return 0;
}

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

using namespace std;

int main() {
	int MIN1 = 100000;
	int MIN2 = 100000;
	int a;

	for (int i = 0; i < 3; i++) {
		cin >> a;
		MIN1 = min(MIN1, a);
	}

	for (int i = 0; i < 2; i++) {
		cin >> a;
		MIN2 = min(MIN2, a);
	}

	cout << MIN1+MIN2-50 << endl;

	return 0;
}

C++: #include<iostream>
#include<string>
#include<algorithm>
#include<vector>
#include<iomanip>
#include<math.h>
#include<complex>
#include<queue>
#include<deque>
#include<stack>
#include<map>
#include<set>
#include<bitset>
#include<functional>
#include<assert.h>
#include<numeric>
#include<stdio.h>
#include <cstdint>
using namespace std;
#define REP(i,m,n) for(int i=(int)(m) ; i < (int) (n) ; ++i )
#define rep(i,n) REP(i,0,n)
using ll = long long;
const int inf = 1e9 + 7;
const ll longinf = 1LL << 60;
const ll mod = 1e9 + 7;


int tmp[5], n[2], ans;

int main(){

	rep(i, 3)cin >> tmp[i];
	rep(i, 2)cin >> n[i];

	sort(tmp, tmp + 3);
	sort(n, n + 2);
	ans = tmp[0] + n[0] - 50;

	cout << ans << endl;


	return 0;
}

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

int main(){
int a,b,c,d,e,f.g;
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){
g=d;
}

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

return 0;
}

C++: #include <algorithm>
#include <climits>
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <functional>
#include <iostream>
#include <map>
#include <ostream>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
#define INF 1000000000
#define rep(i,a,b) for (int i=(a);i<(b);i++)
#define rev(i,a,b) for (int i=(a)-1;i>=b;i--)
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;
typedef queue<int> qi;
typedef vector<int> vi;
typedef vector<string> vs;
int dx[4] = { 0, 1, 0, -1 };
int dy[4] = { 1, 0, -1, 0 };

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

  int p = INF, g = INF;
  rep(i,0,3) {
    int a;
    cin >> a;
    p = min(p, a);
  }
  rep(i,0,2) {
    int a;
    cin >> a;
    g = min(g, a);
  }

  cout << p+g-50 << endl;


	return 0;
}

C++: #include <cstdio>

using namespace std;

int main()
{
	int price;
	int min_p = 3000, min_j = 3000;
	for (int i = 0; i < 3; i++){
		scanf("%d", &price);
		
		if(min_p > price) min_p = price;
	}
	
	for (int i = 0; i < 2; i++){
		scanf("%d", &price);
		
		if(min_j > price) min_j = price;
	}
	
	printf("%d\n", min_p + min_j - 50);
	
	return (0);
}

C++: #include <bits/stdc++.h>
#define range(i, a, b) for(int i = (a); i < (b); i++)
#define rep(i, a) range(i, 0, a)
using namespace std;

int main() {
    int a[3], b[2];
    rep (i, 3) cin >> a[i];
    rep (i, 2) cin >> b[i];

    cout << min({a[0], a[1], a[2]}) + min(b[0], b[1]) - 50 << 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);
	printf("%d\n",pa[0]);
	x=pa[0]+ju[0]-50;
	printf("%d\n",x);
	return 0;
}