/*【程序9】
题目:一个数如果恰好等于它的因子之和,这个数就称为"完数"。例如6=1+2+3.编程找出1000以内的所有完数。*/
packagetest;
importjava.util.ArrayList;
importjava.util.List;
publicclasstest{
publicstaticbooleanovernum(intnumber){
List<Integer>list=..
分类:
编程语言 时间:
2014-05-27 03:34:38
阅读次数:
245
/*【程序7】
题目:输入一行字符,分别统计出其中英文字母、空格、数字和其它字符的个数。
1.程序分析:利用while语句,条件为输入的字符不为‘\n‘.*/
packagetest;
importjava.util.ArrayList;
importjava.util.List;
publicclasstest{
publicstaticList<Integer>countstr..
分类:
编程语言 时间:
2014-05-27 03:32:01
阅读次数:
375
由于只是开发环境,所以都是选择比较简单的apt-get安装方式
,但中间也遇到一点问题。首先安装nginxnginx的安装和配置其实很简单,nginx本身非常轻量级,直接 sudo apt-get install nginx
就可以了他的配置文件是在/etc/nginx/里面,网站项目路径是在/va...
分类:
Web程序 时间:
2014-05-27 02:28:29
阅读次数:
306
很多时候大家需要iframe自适应所加载的页面高度而不要iframe滚动条,但是这次我需要的是页面不需要滚动条而iframe要滚动条,且iframe自动跟随窗口大小变化、自适应页面大小。下面是代码,下次有时间在来解释下代码。$(document).ready(function(){//调用函数va....
分类:
Web程序 时间:
2014-05-27 01:05:09
阅读次数:
263
Reverse digits of an integer. Example1: x =
123, return 321 Example2: x = -123, return –321 这道题应该不用详细说了。比较简单。唯一的是要注意特殊值0.
public class Solution { publ...
分类:
其他好文 时间:
2014-05-24 01:39:59
阅读次数:
170
Digital Roots
时间限制: 1 Sec 内存限制: 128 MB
提交: 91 解决: 29
[提交][状态][论坛]
题目描述
The digital root of a positive integer is found by summing the digits of the integer. If the resulting value is a single d...
分类:
其他好文 时间:
2014-05-22 13:01:21
阅读次数:
223
题目:Given an integer, convert it to a roman numeral.
Input is guaranteed to be within the range from 1 to 3999.
罗马表示方式如下:
I = 1;
V = 5;
X = 10;
L = 50;
C = 100;
D = 500;
M = 1000;
其中每...
分类:
其他好文 时间:
2014-05-22 13:00:09
阅读次数:
240
1、 创建表完整语法
CREATE TABLE [schema.]table
(column datatype [, column datatype] … )
[TABLESPACE tablespace]
[PCTFREE integer]
[PCTUSED integer]
[INITRANS integer]
[MAXTRANS integer]
[STORAGE sto...
分类:
数据库 时间:
2014-05-22 06:25:53
阅读次数:
384
D. Number theory
Time Limit: 1000ms
Case Time Limit: 1000ms
Memory Limit: 65536KB
64-bit integer IO format: %lld Java class name: Main
Submit Status PID:
34055
Font Size:
+
...
分类:
其他好文 时间:
2014-05-20 16:24:12
阅读次数:
245
integer to String :int i = 42;String str =
Integer.toString(i);orString str = "" + i double to String :String str =
Doubl...
分类:
编程语言 时间:
2014-05-20 12:54:45
阅读次数:
358