FOJ 1106 Sum of Factorials
来源:互联网 发布:java基础电影售票系统 编辑:程序博客网 时间:2024/06/05 22:54
http://acm.fzu.edu.cn/problem.php?pid=1106
题目大意:第一段都是讲废话,第二段才进入正题。题目要求的就是给你一个数N,问你它可不可以表示成为若干个数的阶乘的和,可以就输出“YES”,否则“NO”。输入以负数作为结束标志。
解题思路:题目给的范围就1百万,10!就超过了,所以就只要判断这个数能不能被0!~9!来表示,打个0!~9!的表,如果K!<n,n-K!,如此循环,如果n = 0,则可以,n<0就不可以。
- FOJ 1106 Sum of Factorials
- 【FOJ 1106】Sum of Factorials
- Problem 1106 Sum of Factorials
- FZU 1106 Sum of Factorials
- FZU 1106 Sum of Factorials
- Problem 1106 Sum of Factorials
- Sum of Factorials
- Sum of Factorials
- Sum of Factorials
- Sum of Factorials zoj
- poj1775 - Sum of Factorials
- 1038.Sum of Factorials
- fjnu 1050 Sum of Factorials
- poj 1775 Sum of Factorials
- zoj 2358 Sum of Factorials
- poj 1775 Sum of Factorials
- POJ 1775 Sum of Factorials
- HOJ 1302 Sum of Factorials
- 识别CSDN的验证码
- #define new DEBUG_NEW...
- Struts2 AJAX 验证
- ASP.NET调用存储过程两种方法浅析
- C#面试题
- FOJ 1106 Sum of Factorials
- 周末无事
- 大量数据优化常用方法
- 十七大之后我国经济社会发展的基本趋势
- C#里面的string和String的区别
- 从VS2008项目转为VS2005项目(C#版网络转载)
- 传智播客Hibernate视频教程学习笔记8
- AO开发缓冲区的生成
- C#引用参数和输出参数的区别