Dishes and Ingredients
CodeChefOpen on judge ↗
Amit is a good chef who enjoys preparing new dishes from his favourite recipe book. He has $n$ ingredients available with him which are represented in an array $A$ , each ingredient represented as an integer. He wanted to prepare a new dish which requires $k$ ingredients. Help Amit to find whether he could complete his dish or not. ###Input: - First line is an integer $n$, number of ingredients.
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start