| ||||||||||
| Online Judge | Problem Set | Authors | Online Contests | User | ||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest | |||||||||
运行时间太慢了,哪位大虾帮帮忙,不胜感激#include <iostream>
using namespace std;
int main()
{
int countOfNumber = 0;
int countOfZero = 0;
long int number;
cin >> countOfNumber;
for(int i = 0; i < countOfNumber; i++)
{
cin >> number;
countOfZero = 0;
long int tem = (number / 5);
countOfZero += tem;
while (tem >= 5 )
{
tem = (tem / 5) ;
countOfZero += tem;
}
cout << countOfZero << endl;
}
return 0;
}
Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator