【题意】:输入两个数,Y和N。输出从Y(如果Y是闰年则包含Y)开始的第N个闰年。
【代码:AC】
#include
#include
#include
#include
#include
using namespace std;
int isLeapYear(int year)
{
if ((year%4 == 0 && year%100 != 0) || (year%4...
分类:
其他好文 时间:
2015-01-31 00:34:17
阅读次数:
134
If you do much work on computers, eventually you find that there’s some task you’d like to automate. For example, you may wish to perform a search-and...
分类:
移动开发 时间:
2015-01-30 19:00:42
阅读次数:
183
USER: Jeremy Wu [wushuai2]TASK: ariprogLANG: C++Compiling...Compile: OKExecuting... Test 1: TEST OK [0.005 secs, 11880 KB] Test 2: TEST OK [0.008 ...
分类:
其他好文 时间:
2015-01-29 22:27:48
阅读次数:
301
本文演示如何在Android中实现程序前后台切换效果。 在介绍程序实现之前,我们先看下Android中Activities和Task的基础知识。 我们都知道,一个Activity 可以启动另一个Activity,即使这个Activity是定义在别一个应用程序里的,比如说,想要给用户展示一个地图的.....
分类:
移动开发 时间:
2015-01-29 19:19:00
阅读次数:
236
IDT(Interrupt Descriptor Table)仅能存放 interrupt-gate、trap-gate 和 task-gate。指令: int 0x80 ----------------------------------- 0x80 是 vector (中断向量号) ...
分类:
其他好文 时间:
2015-01-29 19:17:54
阅读次数:
145
直接 call / jmp 目标 code segment 不能改变当前的 CPL,若要 call / jmp 高权限的 code segment 必须使用 call gate,在 x86 下还要可以 call / jmp TSS descriptor 或者 call / jmp task gate...
分类:
其他好文 时间:
2015-01-29 19:09:58
阅读次数:
168
指令: call 0x20:00000000 jmp 0x20:00000000 -----------------------------------selector 0x20 是个 task gate 的 selector 这里使用 task gate 任务切换与使用 TSS selec...
分类:
其他好文 时间:
2015-01-29 19:09:38
阅读次数:
136
在 long mode 下,gate 是 16 字节的,并取消了对 task gate 的支持。即 IDT 的 entry 是 16 字节的,所以:gate = IDTR.base + vector * 16。 在 long mode 下,code segment descriptor 的 L、D....
分类:
其他好文 时间:
2015-01-29 18:59:28
阅读次数:
287
The Task Parallel Library (TPL) is a set of public types and APIs in theSystem.ThreadingandSystem.Threading.Tasksnamespaces. The purpose of the TPL is...
分类:
编程语言 时间:
2015-01-29 17:13:25
阅读次数:
144
uva 10344 23 out of 5
Your task is to write a program that can decide whether you can find an arithmetic expression consisting of five given numbers
(1
For this problem we will only consid...
分类:
其他好文 时间:
2015-01-29 14:45:06
阅读次数:
154