classSolution{public:inttitleToNumber(strings){int res =0;for(auto x : s) res = res *26+(x -'A'+1);return res;}};
172 - 阶乘后的零
一个数末尾的0 -> 取决于因式分解中能找到多少个10 -> 多少个 2 * 5;
所以质因数分解,找到2因子的个数a 5因子的个数b 取min(a, b)即可
分解质因数就是试除法 复习一下试除法求质因数
voiddivide(intx){for(int i =2; i <= x / i; i ++){if(x % i ==0){int s =0;while(x % i ==0) x /=i, s++; cout << x <<''<< s <<endl;}// ! 注意这里if(x >1) cout << x <<''<<1<< endl;}}