Loop statement with condition - while




Task
Time limit: 1000 ms,
Memory limit: 256 Mb

Given a natural number N and the number k. Count the number of times k in number N

Input:
The first line sets the number N (N> 0)
The second line contains the number k (0 <= k <= 9)
Output:
It is necessary to print the number of digits k in the number N

Examples
Input Output
1 5345
5
2

Prohibited statements:list;[;find;index

Auto CHOOSE THE PROGRAMMING NECESSARY LANGUAGE!
Attach the program source file:
or enter the source code in the language:

Rules for designing programs and a list of errors during automatic task verification
           

Results: