CF - Team Building
Authors: Sofia Yang, Kevin Sheng
Implementation
Time Complexity:
C++
#include <bits/stdc++.h>using namespace std;int main() {int pool_size;int team_size;int aud_size;cin >> pool_size >> team_size >> aud_size;vector<pair<int, int>> aud_contrib(pool_size);for (int i = 0; i < pool_size; i++) {
Java
import java.io.*;import java.util.*;public class TeamBuilding {public static void main(String[] args) throws IOException {BufferedReader br = new BufferedReader(new InputStreamReader(System.in));StringTokenizer st = new StringTokenizer(br.readLine());int poolSize = Integer.parseInt(st.nextToken());int teamSize = Integer.parseInt(st.nextToken());
Alternate Solution
Join the USACO Forum!
Stuck on a problem, or don't understand a module? Join the USACO Forum and get help from other competitive programmers!