CodeChef::FCTRL

 

#include <bits/stdc++.h>
using namespace std ;

int main (){
long long int t ;
cin >> t ;
while (t--){
long long int n ;
cin >> n ;
long long int no_of_zeros{0};
while (n/5 >= 1){
n = n/5 ;
no_of_zeros += n ;
}
cout << no_of_zeros << '\n' ;

}
return 0 ;
}

Comments

Popular posts from this blog

CodeChef::CSUB

How Recursion Works?

Atcoder Educational Dp contest :: C vacation