题目来源:http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemId=3490题意: 给出两个集合Y
, N , 给出区间【low , high】 , 问在 这个区间有多少个这样的数,x , 满足, 集合Y中至少一个数被x 整除, 且 集合 ...
分类:
其他好文 时间:
2014-05-19 10:35:04
阅读次数:
256
浅析C/C++中的switch/case陷阱 先看下面一段代码:
文件main.cpp#includeusing namespace std;int main(int argc, char *argv[]){ int a
=0; switch(a) { case ...
分类:
编程语言 时间:
2014-05-19 07:08:14
阅读次数:
429
Why J-Link?In case you wonder why GNU ARM
Eclipse decided to provide support to SEGGER J-Link, the short answer is:because
ofJ-Link EDUand of SWO.The ...
分类:
其他好文 时间:
2014-05-17 14:43:56
阅读次数:
907
快速排序算法。python实现。 1 # -*- coding: utf8 -*- 2 3
import random 4 5 def partition(mylist, low, high): 6 pivotkey = mylist[low] 7
while low = piv...
分类:
其他好文 时间:
2014-05-17 01:25:40
阅读次数:
305
verilog设计进阶 时间:2014年5月6日星期二 主要收获: 1. 学会使用case语句; 2.
学会使用随机函数$random。 $random: 1. 函数说明:$random函数调用时返回一个32位的随机数,它是一个带符号的整形数。 2.
产生0~59之间的随机数的例子: reg[23:...
分类:
其他好文 时间:
2014-05-16 07:14:30
阅读次数:
327
题目链接:http://poj.org/problem?id=3469
Dual Core CPU
Time Limit: 15000MS
Memory Limit: 131072K
Total Submissions: 18147
Accepted: 7833
Case Time Limit: 5000MS
...
分类:
其他好文 时间:
2014-05-15 06:23:05
阅读次数:
271
戳我去解题You are climbing a stair case. It
takesnsteps to reach to the top.Each time you can either climb 1 or 2 steps. In
how many distinct ways can you ...
分类:
其他好文 时间:
2014-05-15 01:55:06
阅读次数:
251
switch 语句int x = 10switch(x) case
1:print(“sfsd”)breakcase 2:print(“dsdf”)breakdefaultprint(“right”)break
分类:
其他好文 时间:
2014-05-14 23:47:11
阅读次数:
263
还没有处理lambda、上下文等,有待完善。
main
{
for
putsl(eval(getsl))
}
rstr eval(rstr s)
{
s=tokenize(s)
v=s.split(' ')
if v.get(0)!='('
return v.get(0)
next=find(v.sub(2))+2
switch v.get(1)
case '+'
r...
分类:
其他好文 时间:
2014-05-14 15:32:34
阅读次数:
323
K-th Number
Time Limit: 20000MS
Memory Limit: 65536K
Total Submissions: 35704
Accepted: 11396
Case Time Limit: 2000MS
Description
You are working for Macrohard com...
分类:
其他好文 时间:
2014-05-13 14:07:41
阅读次数:
203