Enormous Input Test - CodeChef Solution

Hello coders, today we will be solving Enormous Input Test CodeChef Solution whose Problem code is INTEST. The purpose of this problem is to verify wh

Hello coders, today we will be solving Enormous Input Test CodeChef Solution whose Problem code is INTEST.

Enormous Input Test - CodeChef Solution

Problem

The purpose of this problem is to verify whether the method you are using to read input data is sufficiently fast to handle problems branded with the enormous Input/Output warning. You are expected to be able to process at least 2.5MB of input data per second at runtime.

Input

The input begins with two positive integers n k (n, k<=107). The next n lines of input contain one positive integer ti, not greater than 109, each.

Output 

Write a single integer to output, denoting how many integers ti are divisible by k.

Example

Input:

7 3
1
51
966369
7
9
999996
11

Output:

4

Solution - Enormous Input Test - CodeChef Solution 

Python 3 

#Solution provided by Sloth Coders
N, K = map(int, input().split())
count = 0
while N > 0:
    a = int(input())
    if (a % K == 0):
        count += 1
    else:
        0
    N = N - 1
print(count)        

Disclaimer: The above Problem (Enormous Input Test) is generated by CodeChef but the Solution is provided by Sloth Coders.

Happy Coding !!

A Sloth Who loves to Code

Also Read:

Sloth Coders is a Learning Platform for Coders, Programmers and Developers to learn from the basics to advance of Coding of different langauges(python, Java, Javascript and many more).

Post a Comment