prompt
string
response
string
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.*; import java.io.*; public class A { FastScanner in; PrintWriter out; boolean systemIO = true; public static void quickSort(int[] a, int from, int to) { if (to - from <= 1) { return; } int i = from; int j = to - 1; int x = a[from + (new Random()).nextInt(to - from)]; while (i <= ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.Arrays; import java.util.Scanner; public class DeclinedFinalists { public static void main(String[] args) { Scanner scan = new Scanner(System.in); int n = scan.nextInt(); int[] arr = new int[n]; for (int i = 0; i < arr.length; i++) { arr[i] = scan.nextIn...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
k=int(input()) list_=list(map(int,input().split())) max_=max(list_) if max_<=25: print("0") else: print(max_-25)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.Scanner; public class DeclinedFinalists { public static void main(String[] args) { Scanner l1=new Scanner(System.in); int l2=l1.nextInt(); int l3[]=new int[l2]; for(int i=0;i<l2;i++){ l3[i]=l1.nextInt(); } finalist s1=new finalist(l2,l3);...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner input = new Scanner(System.in); int number = input.nextInt(); int ans = 0; for (int i = number; i > 0; i--) { int x = input.nextInt(); ans = Math.max(ans, x); } if (ans < 25) { System.out.println(0); ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> #pragma comment(linker, "/STACK:1000000000") using namespace std; const int maxn = (int)1e6 + 10; bool used[maxn]; int main() { int n; cin >> n; int y = 0; for (int i = 0; i < n; i++) { int x; scanf("%d", &x); used[x] = true; } int z = 25 - n; int pos = 1; while (z >...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int k; cin >> k; int a[k]; for (auto &it : a) cin >> it; sort(a, a + k, greater<int>()); int declined = max(a[0], 25) - 25; cout << declined; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> bool fsor(int a, int b) { return (a > b); } using namespace std; int main() { int k, a[40]; int ans = 0; cin >> k; for (int i = 0; i < k; i++) { cin >> a[i]; } sort(a, a + k); ans = a[0] - 1; for (int i = 1; i < k; i++) { ans += a[i] - a[i - 1] - 1; } if (ans <= 25 -...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n = int(input()) arr = [int(a) for a in input().split(" ")] m = max(arr) r = m - 25 if r > 0: print(r) else: print(0)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.Scanner; public class Solution { public static void main(String[] args) { Scanner kbd = new Scanner(System.in); String input = kbd.nextLine(); int numFinalist = Integer.parseInt(input); input = kbd.nextLine(); Scanner scan = new Scanner(input); int num = Integer.parseInt(scan.ne...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.io.IOException; import java.util.Scanner; public class Solutions { public static void main(String[] args) throws IOException { Scanner sc = new Scanner(System.in); int k = sc.nextInt(); int max = -1; for(int i =0; i < k; i++) { int r = sc.nextInt(); if(r > max) max = r; } if(...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
K = int(input()) r = list(map(int, input().split())) print(max(0, max(r) - 25))
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main(int argc, char *argv[]) { int k; cin >> k; int maxRank = 0; for (int i = 0; i < k; i++) { int in; cin >> in; if (in > maxRank) maxRank = in; } if (maxRank < 25) maxRank = 25; cout << maxRank - 25 << endl; return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
k = int(input()) r = sorted(list(map(int, input().split()))) print(0) if r[k-1]<=25 else print(r[k-1]-25)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.io.*; import java.util.*; public class CF859_D12_A { public static void main(String[] args)throws Throwable { MyScanner sc=new MyScanner(); PrintWriter pw=new PrintWriter(System.out); int n=sc.nextInt(); int [] a=new int [n]; TreeSet<Integer> set=new TreeSet<Integer>(); for(int i=0;i<n;i++){...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int64_t N; scanf("%lld", &N); vector<int64_t> have(N); for (int64_t i = 0; i < N; i++) { scanf("%lld", &have[i]); } sort(have.begin(), have.end()); int64_t missing = 0; for (int64_t i = 1; i <= have.back(); i++) { if (find(have.begin(), ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
k = int(input()) ls = list(map(int, input().split(' '))) print(max(max(ls)-25, 0))
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import sys numberKnown = sys.stdin.readline() rankings = sys.stdin.readline() Known = int( numberKnown ) ranksplit = rankings.split() maxrank = 0 for i in range( 0 , len(ranksplit) ): rank = int(ranksplit[i]) if maxrank < rank: maxrank = rank numberDeclined = maxrank - 25 if numberDeclined < 0: ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
k = int(input()) a = list(map(int, input().split(' '))) a.sort() print(max(a[-1]-25, 0))
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.io.*; import java.util.*; public class solution { public static void main(String args[]) { Scanner sc = new Scanner(System.in); int k = sc.nextInt(); int[] r = new int[k]; for(int i=0;i<k;i++) { r[i] = sc.nextInt(); } int max = 0; for(int i=0;i<k;i++) { if(r[i]>max) { max ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n=input() t=list(map(int,input().split())) if max(t)<=25: print(0) else: print(max(t)-25)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
//package problems; import java.util.Scanner; public class declinedFinalists { public static void main(String[] args) { Scanner rdr = new Scanner(System.in); int k = rdr.nextInt(); int max = 25; for(int i = 0; i < k; i++) { int temp = rdr.nextInt(); ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
int(input()) li = list(map(int, input().split())) a = max(li) b = a-25 if b < 0: print(0) else: print(b)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int k; int n; int maxs = 0; int ans; cin >> k; for (int i = 0; i < k; i++) { cin >> n; if (n > maxs) { maxs = n; } } if (maxs > 25) { ans = maxs - 25; } else { ans = 0; } cout << ans << endl; return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.Scanner; public class CodeForces { public static void main(String[] args) { Scanner input = new Scanner(new BufferedReader(new InputStreamReader(System.in))); int n = input.nextInt(); int max = 0; for (int i = 0; i < n; i++)...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int n, jk = 0; cin >> n; long long int a[n]; for (int i = 0; i < n; i++) { cin >> a[i]; } sort(a, a + n); jk = a[n - 1] - 25; if (jk < 0) cout << "0"; else cout << jk; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int n, x = -1; cin >> n; for (int i = 1; i <= n; i++) { int a; cin >> a; x = max(x, a); } cout << max(x, 25) - 25; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main(void) { int n; cin >> n; int arr[n]; for (int i = 0; i < n; i++) { cin >> arr[i]; } sort(arr, arr + n); int dif; dif = arr[n - 1] - 25; if (dif < 0) cout << "0"; else cout << dif; return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int n; scanf("%d", &n); vector<int> a(n); for (int i = 0; i < n; i++) { scanf("%d", &a[i]); } int m = *max_element(a.begin(), a.end()); printf("%d", max(0, m - 25)); }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n=int(input()); p=0; t=input(); t=t.split(' '); for x in t: p=max(p,int(x)); print(max(0,p-25));
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#!/usr/bin/python import sys def Ni(): return tuple(map(int, sys.stdin.readline().split())) def Nil(): return map(int, sys.stdin.readline().split()) def Ns(): return tuple(sys.stdin.readline().split()) K = Ni()[0] r = set(Nil()) p = 1 while len(r) < 25: while p in r: p += 1 r.add(p) print max(r) - ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int n, Max = INT_MIN; cin >> n; for (int i = 0; i < n; i++) { int temp; cin >> temp; if (temp > Max) { Max = temp; } } if (Max < 25) { cout << 0; } else { cout << Max - 25; } return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n = int(input()) l=list(map(int,input().split())) m=max(l) if(m>25): print(m-25) else: print(0)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
a = int(input()) l = list(map(int, input().split())) mx = max(l) if mx <= 25: print(0) else: print(mx-25)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n=int(input()) l=list(map(int,input().split())) if max(l)<=25:print(0) else:print(max(l)-25)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int k; cin >> k; int a[k], i; for (i = 0; i < k; i++) cin >> a[i]; sort(a, a + k); int res = a[k - 1] - 25; if (res < 0) res = 0; cout << res << endl; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int i, n, a[100]; long int ma = 0, p; cin >> n; for (i = 0; i < n; i++) cin >> a[i]; for (i = 0; i < n; i++) { if (a[i] > ma) ma = a[i]; } p = ma - 25; if (p <= 0) cout << 0 << endl; else cout << p << endl; return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
def solve(): n = int(input()) l = list(map(int,input().split())) print(max(max(l) - 25,0)) solve()
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
from sys import stdin n = int(stdin.readline()) a = map(int,stdin.readline().split()) print max(0,max(a)-25)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int n, a, tmp; while (a = 0, ~scanf("%d", &n)) { while (n--) scanf("%d", &tmp), a = max(a, tmp); printf("%d\n", max(a - 25, 0)); } return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { ios::sync_with_stdio(false); cin.tie(NULL); ; int k, i, ans = 0, cnt = 25; cin >> k; vector<long long int> v(k); for (i = 0; i < k; i++) { cin >> v[i]; } sort(v.begin(), v.end()); for (i = 0; i < k; i++) { if (v[i] > 25) { ans+...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n, s = int(input()), max(list(map(int,input().split(' ')))) print(0 if s<=25 else s-25 )
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.Arrays; import java.util.Scanner; import java.util.stream.IntStream; public class Task1 { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); scanner.nextLine(); int[] vals = Arrays.stream(scanner.nextLine().split(" ")).mapToInt(Integer::parse...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n=input() s=map(int,raw_input().split(" ")) a=max(s) m=0 if(a>25): m=a-25 print m
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
a = int(input()) s = list(map(int, input().split())) maxc = s[0] for i in range(1, len(s) ): if s[i] > maxc: maxc = s[i] print(max(maxc-25,0))
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.Scanner; import java.util.Arrays; public class sample{ public static void main(String[] args){ Task prog = new Task(); prog.solve(); } static class Task { public void solve() { Scanner kbd = new Scanner(System.in); int num = kbd.nextInt(); int[] nums = new int[n...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n = int(input()) v = input().split(" ") max = 0 for i in v: ii = int(i) if max<ii: max = ii s = max-25 if s < 0: s = 0 print(s)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
input() r = raw_input() l = map(int, r.split(' ')) l.sort() if l[-1] <= 25: print 0 else: print l[-1] - 25
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; #pragma GCC diagnostic ignored "-Wunused-result" long long dp[100000]; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); long long i, j, n, t; cin >> n; vector<long long> a; for ((i) = (0); (i) < (n); ++(i)) { cin >> t; a.push_back(t); } ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
from sys import stdin, stdout n = int(stdin.readline().strip()) line = stdin.readline().strip() array = line.split(' ') max = 0 for x in array: c = int(x) if(c>max): max = c if(n<25): if(max<=25): ans = 0 else: ans = max - 25 else: ans = max - 25 stdout.write(str(ans))
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
input();k=max(map(int,input().split()));print(0 if k<=25 else k-25)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n = int(input()) l = list(map(int,input().split())) print(max(max(l) - 25,0))
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { ios_base::sync_with_stdio(0); cin.tie(0); int n; int Max = 0; cin >> n; for (int i = 0; i < n; i++) { int x; cin >> x; Max = max(Max, x); } cout << max(Max - 25, 0); return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
k = int(input()) arr = [int(x) for x in input().split()] max_ = max(arr) - 25 if max_ > 0: print(max_) else: print(0)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
k=int(input()) z=list(map(int,input().split())) print(max(0,max(z)-25))
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int k; cin >> k; int max = 0; int curr; for (int i = 0; i < k; i++) { cin >> curr; if (curr > max) { max = curr; } } cout << (((max - 25) > 0) ? (max - 25) : 0); }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#!/bin/python3 import sys n=int(input()) num=list(map(int,input().split())) print(max(max(num)-25,0))
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int a[30]; int main() { int n, i, x; cin >> n; for (i = 0; i < n; i++) cin >> a[i]; sort(a, a + n); x = a[n - 1] - 25; if (x <= 0) x = 0; cout << x; return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
k, r = int(input()), list(map(int, input().split())) print(max(0, max(r) - 25))
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int n, maxa; int main() { cin >> n; for (int i = 0; i < n; i++) { int a; cin >> a; maxa = max(maxa, a); } cout << max(maxa - 25, 0) << endl; return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int k; cin >> k; int mx = 0; int x; for (int i = 1; i <= k; i++) { cin >> x; mx = max(mx, x); } if (mx > 25) { cout << mx - 25; } else { cout << 0; } return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.io.OutputStream; import java.io.IOException; import java.io.InputStream; import java.io.PrintWriter; import java.io.OutputStream; import java.io.IOException; import java.io.InputStreamReader; import java.io.FileNotFoundException; import java.util.StringTokenizer; import java.io.Writer; import java.io.Buffer...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import sys _ = sys.stdin.readline() parts = sys.stdin.readline().strip().split(' ') seq = [int(part) for part in parts] m = max(seq) print max(m - 25, 0)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n = int(input()) li= list(map(int,input().split())) a = max(li) if a>25: print(a-25) else: print(0)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n = int(input()) m = list(map(int,input().split())) max = max(m) if(max-25>=0): print(max-25) else: print(0)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
t = int(input()) s = [int(x) for x in input().split(" ")] if max(s) >= 25: result = min(max(s) - t, max(s) - 25) else: result = 0 print(result)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.Scanner; public class Problem_A { public static void main(String[] args) { // TODO Auto-generated method stub Scanner s=new Scanner(System.in); int k=s.nextInt(); int max=0; for(int i=0;i<k;i++) { int n=s.nextInt(); m...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> int max(int a, int b) { if (a > b) return a; else return b; } int main() { int k, n = 0, i, j = 0, l, m = 0, a = 0, b = 0; int A[50]; scanf("%d", &k); for (i = 0; i < k; i++) { scanf("%d", &A[i]); } a = A[0]; if (k == 1) { if (A[0] > 25) { printf("%d\n", ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> int main() { int a[25]; int K, r, size = 0; scanf("%d", &K); for (int i = 0; i < K; ++i) { scanf("%d", &r); if (r > 25) { a[size++] = r; } } for (int i = 0; i < size; ++i) { for (int j = i + 1; j < size; ++j) { if (a[i] > a[j]) { int temp = a[i]; ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
def invited(lst): return max(0, max(lst) - 25) n = int(input()) a = [int(i) for i in input().split()] print(invited(a))
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ import java.util.*; import java.io.*; /** * * @author rahul kumar */ public class Main { /** * @param args the command l...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; long long int n, k, v, m, ans, sum, sum1, l, r, i, j, mx, mn = 9999, c, z, x, y, a[111111], d[111111], t[111111]; string s, sos, ss; char ch, chel; bool used[111111]; int main() { ios_base::sync_with_stdio(0); cin.tie(0); cin >> n; for (i = 1; i <= n; i++) { ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.*; import java.math.*; public class CP { public static void main(String[] args) { Scanner sc = new Scanner (System.in); int n = sc.nextInt(); int max = 0; for(int i = 0; i < n; i++) { int a = sc.nextInt(); if (a > max) { max = a; } } if(max <= 25) { System.out.println(0); ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
def ni(): return int(raw_input()) def nis(): return map(int, raw_input().split()) n = ni() a = nis() a.sort() print max(0, a[-1] - 25)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n = int(input()) s = list(map(int, input().split())) m = max(s) if m <= 25: print(0) else: print(m-25)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; int maxVal = -1e9; for (int i = 0; i < n; i++) { int val; cin >> val; maxVal = max(maxVal, val); } cout << max(maxVal - 25, 0); return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.*; public class Main { public static void main(String[] args) { Scanner sc=new Scanner(System.in); int n=sc.nextInt(); int[] x=new int[n]; for(int i=0;i<n;i++) { x[i]=sc.nextInt(); } Arrays.sort(x); int a=x[n-1]-25; if(a>0) System.out.print(a); else System.out.print(0); } }...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> #pragma comment(linker, "/STACK:256000000") using namespace std; int main() { ios_base::sync_with_stdio(0); cin.tie(0); int k; cin >> k; int mx = -1; for (int i = 0; i < int(k); ++i) { int a; cin >> a; if (a > mx) mx = a; } int ans = mx - 25; if (ans < 0) ans = 0; ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
k = int(input()) r = [int(x) for x in input().split()] print(max(max(r) - 25, 0))
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int n, b, c, i; int main() { cin >> n; for (i; i < n; i++) { cin >> b; if (b > c) c = b; } if (c > 25) cout << c - 25; else cout << 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0); int K, x, mx = 0; cin >> K; for (int i = 0; i < K; i++) cin >> x, mx = max(mx, x); cout << max(0, mx - 25) << endl; return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
k = int(input()) arr = list(map(int,input().split())) arr.sort() if arr[k-1] - 25 > 0: print(arr[k-1] - 25) else: print("0")
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int n, a[10005], i, maxim; int main() { cin >> n; for (i = 1; i <= n; i++) cin >> a[i]; maxim = a[1]; for (i = 2; i <= n; i++) if (a[i] > maxim) maxim = a[i]; if (maxim > 25) cout << maxim - 25; else cout << '0'; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n=int(input()) a=list(map(int,input().split())) if max(a)>25: print(max(a)-25) else: print("0")
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.Arrays; import java.util.Scanner; public class Finalists { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); int arr[] = new int[n]; for (int i=0;i<n;i++) { arr[i] = sc.nextInt(); } Arrays.sort(arr); if (arr[n-1]>25) { int diff = arr[n-1]-...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.Scanner; public class DeclinedFinalists { public static int max(int a , int b){ if(a>=b){ return a; }else{ return b; } } public static void main(String[] args) { Scanner sc = new Scanner (System.in); int k = sc.nextInt(), a = sc.nextInt(); for(int j=1;j<k;j++) { ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
finalists = int(input()) ranks = list(map(int, input().split())) if max(ranks) <= 25: print(0) else: print(max(ranks) - 25)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n = int(input()) contestants = [int(i) for i in input().split(' ')] contestants.sort(reverse=True) if n <= 25 and contestants[0] > 25: print(contestants[0] - 25) # elif n == 25 and contestants[0] > 25: print(contestants[0] - 25) else: print(0)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
K = int(input()) R = list(map(int, input().split())) R.sort() iv = [False]*(R[-1]+1) for r in R: iv[r] = True ans = 0 for r in range(1, R[-1]+1): if not iv[r] and K < 25: iv[r] = True K += 1 if not iv[r]: ans += 1 print(ans)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { ios::sync_with_stdio(0); int n; cin >> n; int a[n]; for (int i = 0, _ = n; i < _; i++) cin >> a[i]; sort(a, a + n); int save = 25 - n; long long ans = 0; int j = 0; for (int i = 1, _ = a[n - 1]; i < _; i++) { if (a[j] != i) { if (s...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.io.*; //PrintWriter import java.math.*; //BigInteger, BigDecimal import java.util.*; //StringTokenizer, ArrayList public class MemSql_2017_R1_A { FastReader in; PrintWriter out; public static void main(String[] args) { new MemSql_2017_R1_A().run(); } void run() { in = new FastReader...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n=int(input()) e=25-n a=[int(i) for i in input().split()] i=1 while(e>0): if(i not in a): a.append(i) e=e-1 i=i+1 else: i=i+1 f=0 for i in range(1,max(a)+1): if(i not in a): f=f+1 print(f)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> int main() { int x; scanf("%d", &x); int max = -1; for (int i = 0; i < x; i++) { int t; scanf("%d", &t); if (max < t) { max = t; } } if ((max - 25) < 0) { printf("0"); } else { printf("%d", (max - 25)); } return 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
import java.util.*; public class DeclinedFinalists { public static void main(String[] args) { Scanner sc=new Scanner(System.in); int n=sc.nextInt(); int arr[]=new int[n]; for(int i=0;i<n;i++) { arr[i]=sc.nextInt(); } Arrays.parallelSort(arr); if(arr[n-1]<=25) { System.out.println(0); } else { ...
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
final=int(input()) rank=list(map(int, input().split())) m=max(rank) if m<=25: print(0) else: print(m-25)
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { ios_base::sync_with_stdio(false); cin.tie(0); int k; cin >> k; vector<int> v(k); for (int i = 0; i < k; i++) { cin >> v[i]; } sort(v.begin(), v.end()); if (v.back() > 25) cout << v.back() - 25; else cout << 0; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { long long k; cin >> k; long long arr[k + 1], i, j = 0; for (i = 1; i <= k; i++) { cin >> arr[i]; } sort(arr + 1, arr + k + 1); cout << max(j, arr[k] - 25); }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
#include <bits/stdc++.h> using namespace std; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); int n; cin >> n; int ans = 0; for (int i = 0; i < n; i++) { int x; cin >> x; ans = max(ans, x - 25); } cout << ans << endl; }
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
a = input() list_ = map(int,raw_input().split()) try: print max(filter(lambda x:x>25,list_))-25 except: print 0
Problem: This year, as in previous years, MemSQL is inviting the top 25 competitors from the Start[c]up qualification round to compete onsite for the final round. Not everyone who is eligible to compete onsite can afford to travel to the office, though. Initially the top 25 contestants are invited to come onsite. Each ...
n = int(input()) l = [int(i) for i in input().split()] if max(l)-25 < 0: print(0) else: print(max(l) - 25)