/**
*功能:编写一个程序使用两重for循环和模运算符(%)去寻找和输出质数(只能被1和它本身
*整除的整数)。
*时间:2014年8月15日08:19:48
*作者:cutter_point
*/
#include
#include
using namespace std;
//写一个函数输出质数(只能被1和它本身*整除的整数)
void printZhiShu(int n) ...
分类:
编程语言 时间:
2014-08-15 09:34:17
阅读次数:
223
A robot is located at the top-left corner of a m x n grid (marked 'Start' in the diagram below).The robot can only move either down or right at any point in time. The robot is trying to reach the bottom-right corner of the grid (marked 'Finish' in the diag...
分类:
其他好文 时间:
2014-08-15 09:32:37
阅读次数:
200
DescriptionAssume the coasting is an infinite straight line.Land is in one side of coasting, sea in the other.Each small island is a point locating in...
分类:
其他好文 时间:
2014-08-15 01:28:36
阅读次数:
217
import java.awt.Cursor;
import java.awt.Graphics;
import java.awt.Graphics2D;
import java.awt.Point;
import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;
import java.awt.event.M...
分类:
编程语言 时间:
2014-08-14 20:51:09
阅读次数:
212
http://poj.org/problem?id=2151
有t个队伍,m道题,给出每个队伍做出每道题的概率。求出每个队伍至少做出一道题并且冠军队伍至少做出n道题的概率。
只要设出数组来,就很直观了。
dp[i][j][k]表示第i个队伍在前j道题中解出k道题的概率,s[i][j]表示第i个队伍最多解出j道题的概率。
首先初始化dp[i][0][0]和dp[i][j][0...
分类:
其他好文 时间:
2014-08-14 20:35:09
阅读次数:
193
加上引用: using System.Text.RegularExpressions; /// /// 检查字符串是否是日期格式 /// /// 2011-5-8 8:08:05 /// public static string check(string s) { if (Regex.I...
分类:
Web程序 时间:
2014-08-14 19:26:19
阅读次数:
369
java数据类型: 1)原始类型:Primitive Types(原始值) 数值类型(Numeric Types) 整型类型(Integral Types),浮点类型(Floating-Point Types) 布尔类型(Boolean Types) returnAddress类型:表示一条字节...
分类:
编程语言 时间:
2014-08-14 14:20:58
阅读次数:
287
/**
* 功能:使用函数指针
* 时间:2014年8月14日07:23:42
* 作者:cutter_point
*/
#include
#include
using namespace std;
void fun1()
{
cout<<"The function fun1 called.."<<endl;
}
int main()
{
void (*fp)(); /...
分类:
编程语言 时间:
2014-08-14 08:17:28
阅读次数:
231
/**
* 功能:指向函数的指针数组
* 时间:2014年8月14日07:24:46
* 作者:cutter_point
*/
#include
#include
using namespace std;
//这里N就是函数名,而DF(N)就代表了后面的N函数,N可以变
#define DF(N) void N() {cout<<"function "#N...
分类:
编程语言 时间:
2014-08-14 08:17:18
阅读次数:
220
[root@ipaserver~]#yuminstallipa-serverTransactionCheckError:file/usr/share/man/man3/XML::SAX::Base.3pm.gzconflictsbetweenattemptedinstallsofperl-XML-SAX-0.96-7.el6.noarchandperl-XML-SAX-Base-1.04-1.el6.rf.noarchfile/usr/share/man/man3/XML::SAX::Exception.3p..
分类:
其他好文 时间:
2014-08-14 04:05:58
阅读次数:
482