leetcodeSolution to some Leetcode problems written in C++ |
git clone git://git.dimitrijedobrota.com/leetcode.git |
Log | Files | Refs | README | LICENSE | |
0172.cpp (167B)
1 class Solution { 2 public: 3 int trailingZeroes(int n) const { 4 int res = 0; 5 while (n > 0) 6 n /= 5, res += n; 7 return res; 8 } 9 };