Team Challenge
Practice this coding question on Coding Gurukul.
Problem statement
Three Coding Gurukul students form a team for a coding contest containing N problems. For each problem, every student reports their confidence: - 1 means confident about the solution. - 0 means not confident. The team attempts a problem only if at least two students are confident. Find the total number of problems the team will attempt.
Input format
The first line contains an integer N — the number of problems. Each of the next N lines contains three space-separated integers A, B, and C — the confidence values of the three students for that problem.
Output format
Print a single integer — the number of problems the team will attempt.
Constraints
1 <= N <= 1000 A, B, C are each either 0 or 1.
Sample input
4 1 0 1 0 0 1 1 1 1 0 1 0
Sample output
2
Sign in to run or submit a solution in C++, Java or Python.