摘要:
查找Time Limit 1000msMemory Limit 65536Kdescription给你一串没有重复数字的递增序列,我们想要知道自己输入的数字在该序列的哪个位置。当然该序列的数字比较多。 input测试数组有多组,每组测试数据第一行输入一个整数n,(1 2 #include 3 using namespace std; 4 5 int main() 6 { 7 int n,m,s,e,t,x,f,k,i,a[100001]; 8 while(cin>>n) 9 {10 for(i=0;i>t;12 for(i...
阅读全文
摘要:
DescriptionOne hot summer day Pete and his friend Billy decided to buy a watermelon. They chose the biggest and the ripest one, in their opinion. After that the watermelon was weighed, and the scales showed w kilos. They rushed home, dying of thirst, and decided to divide the berry, however they fac
阅读全文
摘要:
DescriptionGetting in LineComputer networking requires that the computers in the network be linked.This problem considers a ``linear" network in which the computers are chained together so that each is connected to exactly two others except for the two computers on the ends of the chain which a
阅读全文
摘要:
Description Where is the Marble?Raju and Meena love to play with Marbles. They have got a lot of marbles with numbers written on them. At the beginning, Raju would place the marbles one after another in ascending order of the numbers written on them. Then Meena would ask Raju to find the first marbl
阅读全文