← All problemsSign in

Matrix Again

CodeChefRating 1970Open on judge ↗

In every contest there should be an easy problem about matrices. December Cook-Off is not an exception. Given a matrix A which consists of n rows and m columns, and contains integer numbers. Consider every possible vector v of m elements, such that every 1 ≤ vi ≤ n. Let value of the vector be product of all Avi, i (1 ≤ i ≤ m). You are to count the sum of values over all possible vectors v. Inp

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.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start