1245专题

wikioi 1245 小顶堆

题目描述 Description 有两个长度为 N 的序列 A 和 B,在 A 和 B 中各任取一个数可以得到 N^2 个和,求这N^2 个和中最小的 N个。 输入描述 Input Description 第一行输入一个正整数N;第二行N个整数Ai 且Ai≤10^9;第三行N个整数Bi, 且Bi≤10^9 输出描述 Output Descriptio

Saving James Bond HDU - 1245(多源点 floyd)

This time let us consider the situation in the movie “Live and Let Die” in which James Bond, the world’s most famous spy, was captured by a group of drug dealers. He was sent to a small piece of land

题目 1245: 神奇的fans

题目描述 传说fans是一个数学天才。在他五岁那年,从一堆数字卡片中选出了4张 卡片:5,7,6,8。这4个数字有什么神秘之处呢?如果把这4张卡片自左往右的排成:5,6,7,8。你就会发现:原来这4个数字构成了等差数列!当年 fans选出了n组卡片,据说都能够构成等差数列。但是事实真的是这样吗?fans真的有这么神奇吗? n组数据就是fans选出的n组卡片,请你判断每一组卡片是否能构成等差

XTU 1245 Lisa’s Puzzle

Lisa’s Puzzle[ Submit Code ] [ Top 20 Runs ]Acceteped : 18   Submit : 145 Time Limit : 1000 MS Memory Limit : 65536 KB Description Lisa’s Puzzle 题目描述 5的二进制是101,13的二进制是1101,所以在二进制上,5是13的后缀。Lisa获得

Harmonic Number (II) LightOJ - 1245

求f(n)=n/1+n/2…n/n,其中n/i保留整数 f(n)这个函数刚好关于y=x对称,对称点位sqrt(n); 所以ans2-nn就可以求出来了 #include<stdio.h>#include<cmath>#include<algorithm>#include<iostream>#include<string.h>using namespace std;typedef lo