![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
交互题
文章平均质量分 71
tomjobs
别慌,慌也没用
展开
-
Codeforces-1486 C2. Guessing the Greatest (hard version)(交互,二分)
题意:一个排列,1e5的范围,至多20次询问,每次可以询问一个子段的次大值位置。求最大值的下标位置。思路:通过第一次询问找出次大值位置pospospos,然后询问(1,pos)(1,pos)(1,pos)确定,如果结果等于pospospos,那么最大值是在pospospos左边,否则在pospospos右边。这样就得到了一个确定了最大值所在的区间,且这个区间左边界(或右边界)为次大值。对于左边界为次大值的情况,假设最大值位置为xxx,那么对于i<xi<xi<x的所有的询问(pos原创 2021-02-19 22:29:32 · 184 阅读 · 0 评论 -
D - Experiment! Gym - 102911E(交互,海明码,二进制)
This is an interactive problem.The PIPAC (Philippine Institute of Pure and Applied Chemistry) is an independent scientific institute which lies between Faura Hall and the School of Management in the Ateneo de Manila University. Despite residing in Ateneo,原创 2021-01-26 22:02:19 · 251 阅读 · 0 评论 -
Codeforces-1473 E - Strange Shuffle(交互,巧妙)
This is an interactive problem.???? people sitting in a circle are trying to shuffle a deck of cards. The players are numbered from 1 to ????, so that players ???? and ????+1 are neighbours (as well as players 1 and ????). Each of them has exactly ???? ca原创 2021-01-17 18:01:23 · 278 阅读 · 0 评论 -
Codeforces 1451E2. Bitwise Queries (Hard Version)(交互,二进制)
The only difference between the easy and hard versions is the constraints on the number of queries.This is an interactive problem.Ridbit has a hidden array ???? of ???? integers which he wants Ashish to guess. Note that ???? is a power of two. Ashish is原创 2020-11-22 14:45:47 · 298 阅读 · 0 评论 -
Codeforces1406 E. Deleting Numbers(交互,素数,分块)
This is an interactive problem.There is an unknown integer ???? (1≤????≤????). You want to find ????.At first, you have a set of integers {1,2,…,????}. You can perform the following operations no more than 10000 times:A ????: find how many numbers are m原创 2020-09-16 18:28:56 · 184 阅读 · 0 评论 -
Codeforces1407 C. Chocolate Bunny(交互)
This is an interactive problem.We hid from you a permutation ???? of length ????, consisting of the elements from 1 to ????. You want to guess it. To do that, you can give us 2 different indices ???? and ????, and we will reply with ????????mod???????? (r原创 2020-09-09 08:34:38 · 328 阅读 · 0 评论 -
Interactive Primes Guessing Gym - 100519I(交互,数论)
The jury has chosen the numbers X 0 and P (1 ≤ X 0 < P ≤ N, P is a prime number). You are given the number N: the upper limit for P.Your task is to guess the number P.In order to do that, your program will ask the questions in the form of A i (2 ≤ A i原创 2020-07-07 21:40:49 · 327 阅读 · 0 评论 -
Codeforces 1375 F. Integer Game(交互,博弈)
This is an interactive problem.Anton and Harris are playing a game to decide which of them is the king of problemsetting.There are three piles of stones, initially containing ????, ????, and ???? stones, where ????, ????, and ???? are distinct positive i原创 2020-07-06 00:15:22 · 427 阅读 · 0 评论 -
Codeforces 1363D. Guess The Maximums(交互)
This is an interactive problem.Ayush devised a new scheme to set the password of his lock. The lock has ???? slots where each slot can hold integers from 1 to ????. The password ???? is a sequence of ???? integers each in the range [1,????], ????-th eleme原创 2020-06-01 17:11:37 · 685 阅读 · 1 评论 -
Lost Numbers CodeForces - 1167B(交互题)
This is an interactive problem. Remember to flush your output while communicating with the testing program. You may use fflush(stdout) in C++, system.out.flush() in Java, stdout.flush() in Python or f...原创 2020-04-15 11:36:16 · 573 阅读 · 0 评论 -
Bear and Prime 100 CodeForces - 679A(交互题)
This is an interactive problem. In the output section below you will see the information about flushing the output.Bear Limak thinks of some hidden number — an integer from interval [2, 100]. Your ta...原创 2020-04-15 09:49:26 · 247 阅读 · 0 评论