{"problem":{"name":"Project Planning","description":{"content":"KEYENCE has $N$ departments, where $A_i$ employees belong to the $i$\\-th department $(1 \\leq i \\leq N)$. No employee belongs to multiple departments. The company is planning cross-departmental project","description_type":"Markdown"},"platform":"AtCoder","limit":{"time_limit":2000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"abc227_d"},"statements":[{"statement_type":"Markdown","content":"KEYENCE has $N$ departments, where $A_i$ employees belong to the $i$\\-th department $(1 \\leq i \\leq N)$. No employee belongs to multiple departments.\nThe company is planning cross-departmental projects. Each project will be composed of exactly $K$ employees chosen from $K$ distinct departments.\nAt most how many projects can be made? No employee can participate in multiple projects.\n\n## Constraints\n\n*   $1 \\leq K \\leq N \\leq 2 \\times 10^5$\n*   $1 \\leq A_i \\leq 10^{12}$\n*   All values in input are integers.\n\n## Input\n\nInput is given from Standard Input in the following format:\n\n$N$ $K$\n$A_1$ $A_2$ $\\ldots$ $A_N$\n\n[samples]","is_translate":false,"language":"English"}],"meta":{"iden":"abc227_d","tags":[],"sample_group":[["3 3\n2 3 4","2\n\nThere can be two projects, each composed of three employees from distinct departments."],["4 2\n1 1 3 4","4"],["4 3\n1 1 3 4","2"]],"created_at":"2026-03-03 11:01:14"}}