Control C201C P34451


Statement
 

pdf   zip

html

Your task is to write a program that reads an integer strictly positive x and a sequence of integers, and prints how many elements of the sequence are multiple of x.

Input

The input is an integer x > 0 followed by a sequence of integers.

Output

Your program must print the number of elements of the sequence that are multiple of x.

Public test cases
  • Input

    13
    0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
    
    

    Output

    2
    
  • Input

    2
    -5 -4 -3 -2 -1 0 1 2 3 4 5
    
    

    Output

    5
    
  • Input

    32
    

    Output

    0
    
  • Input

    13
    26 59 13 13 13 26 1
    

    Output

    5
    
  • Information
    Author
    Professorat de P1
    Language
    English
    Translator
    Carlos Molina
    Original language
    Catalan
    Other languages
    Catalan
    Official solutions
    C++
    User solutions
    C++ Python