码迷,mamicode.com
首页 >  
搜索关键字:square    ( 2122个结果
[LeetCode] Spiral Matrix II
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...
分类:其他好文   时间:2015-03-06 16:19:22    阅读次数:128
hdu 1045 Fire Net DFS入门题
Problem Description Suppose that we have a square city with straight streets. A map of a city is a square board with n rows and n columns, each representing a street or a piece of wall. A blockhouse is a small castle that has four openings through which ...
分类:Web程序   时间:2015-03-06 11:21:23    阅读次数:221
第十六章:C预处理器
1.宏(macro)1.1定义宏#define macro bodyexample:#define PI 3.14 //object-like macro#define SQUARE(x) ((x)*(x)) //function-like macro1.2预处理器不进行计算,而只进行字符串替换。比...
分类:其他好文   时间:2015-03-03 20:30:18    阅读次数:117
【node.js学习】--(2)--模块
一个文件就是一个模块exports公开接口创建exports.jsvar i; exports.set = function(num){//设置值 i=num; console.log("seti to "+i); } exports.square = function(){//求平方并输出 i=Math.pow(i,2);...
分类:Web程序   时间:2015-02-28 18:45:50    阅读次数:199
工作中英语积累11
1.获取   acquire 2.取样   sample 3.峰值检测  peak detect 4.方波和脉冲  square waves and pulse 5.耦合  coupling 6.粗调/细调  coarse/fine 7.探头衰减系数   probe attenuation factor 8.反相   invert 9.光轴(最大发光强度中心)   optical ...
分类:其他好文   时间:2015-02-28 10:16:37    阅读次数:178
蓝桥杯校内选拔赛/POJ 数独(深搜)
SudokuTime Limit:2000MSMemory Limit:65536KTotal Submissions:14530Accepted:7178Special JudgeDescriptionSudoku is a very simple task. A square table wit...
分类:其他好文   时间:2015-02-27 01:26:43    阅读次数:215
[LeetCode] Sqrt(x)
Implementint sqrt(int x).Compute and return the square root ofx.解法:二分搜索 时间复杂度O(logN), 空间复杂度O(1) 1 class Solution { 2 public: 3 int sqrt(int x) {...
分类:其他好文   时间:2015-02-25 19:53:35    阅读次数:143
Leetcode 69 Sqrt(x)
Implementint sqrt(int x).Compute and return the square root ofx.求平方根, 用的是二分法. 从 0 - x, 使用二分的思想啊~为了防止overflow, 把low和up用long。然后return int类型就行了~据说还有一种牛顿迭...
分类:其他好文   时间:2015-02-25 08:01:21    阅读次数:143
CodeForces 407A 手速题
//CodeForces 407A 1 #include "iostream" 2 #include "cstdio" 3 #include "cstring" 4 #include "algorithm" 5 using namespace std; 6 int square[1010]; 7 s...
分类:其他好文   时间:2015-02-25 00:42:55    阅读次数:261
hdu 1518 square
Square Time Limit: 10000/5000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 9502    Accepted Submission(s): 3091 Problem Description Given a set of sticks...
分类:其他好文   时间:2015-02-20 15:15:53    阅读次数:180
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!