#lang slideshow(define c (circle 10))(define r
(rectangle 10 20));定义一个调用函数(define (square n) (filled-rectangle n
n));局部绑定(define (four p) (define tw.....
分类:
其他好文 时间:
2014-06-07 05:15:21
阅读次数:
315
题目链接题意
:这个人要投资地,每块地都是正方形并且边长都是整数,他希望他要买的地尽量的少碎块。每买一块地要付的钱是边长的平方,而且会得到一个一份证书,给你一个钱数,让你求出能得到的证书个数。思路
:其实就是求x12+x22+……+Xn2中的最小的n。 1 //1073 2 #include 3 ....
分类:
其他好文 时间:
2014-06-04 20:21:14
阅读次数:
292
Implementint sqrt(int x).Compute and return the
square root
ofx.classSolution{public:intsqrt(intx){inti=0;intstep=1;while(step>0){while((i+step)>1);}r...
分类:
其他好文 时间:
2014-06-04 19:54:17
阅读次数:
214
先看效果:代码上:Work.cpp#include #include #include
#include #include "Work.h"#include "P2PSearchProtocol.h"#include MyQPushButton
*pQPushButton;int main(int ...
分类:
其他好文 时间:
2014-06-04 19:32:54
阅读次数:
591
Given an integern, generate a square matrix
filled with elements from 1 ton2in spiral order.For example,Givenn=3,You should
return the following matri...
分类:
其他好文 时间:
2014-06-04 19:28:23
阅读次数:
220
rsync简介rsync(remote
synchronize)是一个远程数据同步工具,可通过LAN/WAN快速同步多台主机之间的文件。也可以使用rsync同步本??硬盘中的不同目录。rsync是用于替代rcp的一个工具,rsync使用所谓的rsync算法
进行数据同步,这种算法只传送两个文件的不同...
分类:
其他好文 时间:
2014-06-04 18:38:34
阅读次数:
502
一道记忆搜索题,记忆搜索题就是搜索的形式+DP的思想!题目:FatMouse has
stored some cheese in a city. The city can be considered as a square grid of
dimension n: each grid locatio...
分类:
其他好文 时间:
2014-06-03 14:14:28
阅读次数:
466
题目:The sum of the squares of the first ten
natural numbers is,12 + 22 + ... + 102 = 385The square of the sum of the first
ten natural numbers is,(1 + ...
分类:
其他好文 时间:
2014-05-26 02:15:16
阅读次数:
216
Implementint sqrt(int x).Compute and return the
square root ofx.思路:二分查找法解决这道题class Solution {public: int sqrt(int x) { if(x1e-6)
{ ...
分类:
其他好文 时间:
2014-05-25 19:35:33
阅读次数:
225
【题目】
Given an integer n, generate a square matrix filled with elements from 1 to n2 in spiral order.
For example,
Given n = 3,
You should return the following matrix:
[
[ 1, 2, 3 ],
[ 8, 9, 4 ],
[ 7, 6, 5 ]
]
【题意】
给定整数n, 将1,2,3...nxn个数按螺旋旋转的方式填入n...
分类:
其他好文 时间:
2014-05-25 07:08:17
阅读次数:
235