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<stdio.h>
#include<math.h>
#include<algorithm>
#include<cctype>
#include<string.h>
#include <stdlib.h>

#define PI 3.1415926
void swap(int* x, int* y) {
	int a = *x;
	int b = *y;
	*x = b;
	*y = a;
}
int factorial(int n);
int sum(int n, int*);
int ave(int n, int*);
int min(int n, int*), min(int n, int m);
int max(int n, int*), max(int n, int m);

int main() {
	int p1, p2, p3, j1, j2;
	scanf("%d %d %d %d %d", &p1, &p2, &p3, &j1, &j2);
	printf("%d", min(min(p1, p2), p3) + min(j1, j2) - 50);
	return 0;
}

int factorial(int n) {
	if (n > 0) {
		return n * factorial(n - 1);
	}
	else {
		return 1;
	}
}
int sum(int n, int *all) {
	int total = 0;
	for (int i = 0; i < n; ++i) {
		total += all[i];
	}
	return total;
}
int ave(int n, int *all) {
	int total = 0;
	for (int i = 0; i<n; ++i) {
		total += all[i];
	}
	return total / n;
}
int min(int n, int *all) {

	int min = all[0];
	for (int i = 1; i < n; ++i) {
		if (all[0] > all[i]) {
			min = all[i];
		}
	}
	return min;
}
int max(int n, int *all) {
	int max = all[0];
	for (int i = 1; i<n; ++i) {
		if (all[0]<all[i]) {
			max = all[i];
		}
	}
	return max;
}
int max(int n, int m) {
	if (n >= m) {
		return n;
	}
	else {
		return m;
	}
}
int min(int n, int m) {
	if (n >= m) {
		return m;
	}
	else {
		return n;
	}
}

C++: #include <bits/stdc++.h>
using namespace std;
int main()
{
  int data;
  int minv;
  for(int i = 0;i < 3;i++) {
    minv = INT_MAX;
    cin >> data;
    minv = min(data,minv);
  }
  int a,b;
  cin >> a >> b;
  if(a < b)cout << minv + a - 50 << endl;
  else cout << minv + b - 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,min(b,c))+min(d,e)-50)<<endl;
  return 0;
}

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

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

C++: /*
	lunch
*/
#include<iostream>
#include<cstdio>
#include<algorithm>


using namespace std;

int main(void)
{
	//freopen("C:\\Users\\h2539\\Desktop\\in.txt","r",stdin);
	//freopen("C:\\Users\\h2539\\Desktop\\out.txt","w",stdout);

	int p[3] = {0}, d[2] = {0};

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

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

	int maxp = max(p[0], p[1]);
	maxp = max(maxp, p[2]);

	int maxd = max(d[0], d[1]);

	cout << maxp + maxd - 50 << endl;

	return 0;
}

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

using namespace std;

int main(void) {
  int minp = 2000, minj = 2000;
  for (int i = 0; i < 3; i++) {
    int p;
    cin >> p;
    minp = min(minp, p);
  }
  for (int i = 0; i < 2; i++) {
    int j;
    cin >> j;
    minj = min(minj, j);
  }
  cout << minp + minj - 50 << endl;

  return 0;
}

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

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

C++: 
#include<iostream>

using namespace std;

int main(){
	int a=0;
	int b=0;
	int c=0;
	int d=0;
	int e=0;
	
	cin >> a >> b >> c >> d >>e;
	   

					
	if (a<b<c)
	{ 
		cout <<a+min(d,e)-50<<endl;
	}
	else if (a<c<b)
	{
		cout <<a+min(d,e)-50<<endl;
	}
	else if (b<a<c )
	{
		cout <<b+min(d,e)-50<<endl;
	}
	else if (b<c<a )
	{
		cout <<b+min(d,e)-50<<endl;
	}
	else if (c<a<b )
	{
		cout <<c+min(d,e)-50<<endl;
	}
	
	else  if(c<b<a)
	{
		cout <<c+min(d,e)-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] < pmin) {
			pmin = p[i];
		}
	}
	for (int i = 0; i < 2; i++) {
		std::cin >> j[i];
		if (j[i] < jmin) {
			jmin = j[i];
		}
	}
	std::cout << jmin + pmin - 50 << std::endl;

	return 0;
}

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

int main() {
	int pas[3] = {}, juice[2] = {};
	int pm = 0, jm = 0;
	std::cin >> pas[0] >> pas[1] >> pas[2] >> juice[0] >> juice[1];

	pm = std::min({pas[0],pas[1],pas[2]});
	jm = std::min(juice[0],juice[1]);

	std::cout << pm + jm - 50 << std::endl;

	return 0;
}

C++: #include <stdio.h>

int main(){
int a,b,c,d,e;
scanf("%d", &a);
scanf("%d", &b);
scanf("%d", &c);
scanf("%d", &d);
scanf("%d", &e);
if((a<=b)&&(a<=c))
{
    int f=a;
}
else if(b<=c)
{
    int f=b;
}
else
    int f=c;
if(d<=e)
    int g=d;
else
    int g=e;
int h=f+g-50;
printf("%d\n", h);
return 0;
}

C++: #include <iostream>
using namespace std;
int main(){
    int a[5];
    for(int i=0;i<5;i++){
        cin>>a[i];
    }
    int x=a[0];
    int y=a[3];
    if(a[1]<x)x=a[1];
    if(a[2]<x)x=a[2];
    if(a[4]<y)y=a[4];
    cout<<x+y-50<<endl;
}

C++: #include<iostream>
using namespace std;
int main(){
	int a,b,c,d,e;
	int A;
	cin>>a>>b>>c>>d>>e;
	if(a>b&&b>c){
	A+=c;
	}
	else if(b>c&&c>a){
		A+=a;
	}
	else if(c>a&&a>b){
		A+=b;
	}
	
	if(d>e){
		A+=e;
	}
	else if(d<e){
		A+=d;
	}
	cout<<A<<endl;
	return 0;
}

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

#define llong long long
#define inf 999999999
#define mp make_pair
#define pb push_back
#define fn fill_n
typedef pair<int, int> P;
typedef pair<P, int> PP;
typedef pair<PP, int> PPP;
typedef struct data{
	int now;
	int cost;
}data;
int nh[4] = {1, 0, -1, 0};
int nw[4] = {0, 1, 0, -1};





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;
    cin >> a >> b >> c >> d >> e;
    cout << min({a, b, c}) + min(d, e) - 50 << '\n';
}

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

int main() {
	vector<int> vec(3); int jui_a, jui_b, ans;
	for (int i = 0; i < 3; i++) cin >> vec[i];
	cin >> jui_a >> jui_b;
	sort(vec.begin(), vec.end());
	ans = vec[0] + (jui_a > jui_b ? jui_b : jui_a) - 50;
	cout << ans << endl;
	return 0;
}

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

int main(){
  int pas[3],dri[2],sum;
 
  cin >> pas[0] >> pas[1] >> pas[2] >> dri[0] >> dri[1];
  sort(pas,pas+3);
  sort(dri,dri+2);

  sum = pas[0]+dri[0]-50;

  cout << sum << endl;
}

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

C++: #include<stdio.h>
int main(void)
{
	int p,j;
	int i;
	int pm,jm;
	int sm;
	pm=2000;
	jm=2000;
	for(i=0;i<3;i++){
		scanf("%d",&p);
			if(pm>p){
				pm=p;
			}
	}
	for(i=0;i<2;i++){
		scanf("%d",&j);
			if(jm>j){
				jm=j;
			}
	}
	sm=pm+jm-50;
	printf("%d\n",sm);
	return 0;
}

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

int main()
{
	//?????????
	int num1=0,num2=0,num3=0,num4=0,num5=0,num6=0,num7=0,t=0,p=0,h=0;
	cin>>num1>>num2>>num3>>num4>>num5;
	if(num1>num2){
		t=num1;
		num1=num2;
		num2=t;
	}
	if(num1>num3){
		p=num1;
		num1=num3;
		num3=p;
	}
	if(num4>num5){
		h=num4;
		num4=num5;
		num5=h;
	}
	num6=num1+num4-50;
	cout<<num6;
	cout<<"\n";
	return 0;
}