• 「CF549X」Looksery Cup 2015

    「CF549X」Looksery Cup 2015

    A.FaceDetection模拟[crayon-5b519da0be57b144927673/]B.LookseryParty如果当前每个人还需要的信息数都非0,则已构造完否则,找出为0的那个人,让其发一次信息(这个人之后一定<0)[crayon-5b519da0be585439322290/]C.TheGameOfParity如果奇数和偶数城市都足够多,那么最后一个操作的人一定能将局面变成他想要的否则就考虑某一方想将奇数或偶数的城市先取完还要特判一下n=K的情况[crayon-5b519da0be58a953474177/]D...

    82015年6月8日1,795模拟,贪心,构造,二分法
  • NEERC 2014 填坑计划(7 / 12)

    NEERC 2014 填坑计划(7 / 12)

    7/12已弃A简单贪心[crayon-5b519da0bf43d099590764/]B按B/A排序后贪心[crayon-5b519da0bf447885427902/]E写的题解被吞了。。。奇怪的随机化直接看代码好了[crayon-5b519da0bf44d775419309/]F主要是读题上的困难,得出每个文件的二进制串,用bitset判包含[crayon-5b519da0bf452743066069/]I将出现次序作为权,发现合法状态是一个递增序列拼上递减序列然后就是dp啦[crayon-5b519da0bf457038644162/]J搜索可过,因为不合法状态...

  • 「CF534X」Codeforces Round #298 (Div. 2)

    「CF534X」Codeforces Round #298 (Div. 2)

    「cf534A」Examyy个奇怪的构造TT[crayon-5b519da0c00dc763273065/]「cf534B」CoveredPathd很小,最大速度就很小,dp即可[crayon-5b519da0c00e9176931448/]「cf534C」Polycarpus'Dice对于每个骰子,得出其它骰子的和sum则它的最小值为A-sum,最大值为A-n+1[crayon-5b519da0c00ef621313421/]「cf534D」Handshakes尽量大的能处理则处理[crayon-5b519da0c00f4380287982/]「cf534E」BerlandLocalPositioningSystem非...

  • 「CF508E」Arthur and Brackets

    「CF508E」Arthur and Brackets

    Noticethatthememorylimitisnon-standard.RecentlyArthurandSashahavestudiedcorrectbracketsequences.Arthurunderstoodthistopicperfectlyandbecomesoamazedaboutcorrectbracketsequences,soheevengothimselfafavoritecorrectbracketsequenceoflength2n.UnlikeArthur,Sashaunderstoodthetopicverybadly,andbrokeArthur'sfavoritecorrectbracketsequencejusttospitehim.AllArthurremembersabouthisfavoritesequenceisfo...

    02015年1月28日1,368构造
  • 「uoj #5」怎样提高智商

    「uoj #5」怎样提高智商

    大力水手最近和他的女朋友奥利弗分手了,他感到人生非常灰暗,于是上山来找禅师解惑。大力水手问禅师:“大师,奥利弗以前经常说我是个笨蛋,让我觉得很生气。大概是因为我真的太笨了她才这么说吧。请问,怎样才能提高智商?”禅师浅笑,答:“方法很简单,不过若想我教你,你先看看这张试卷。”大力水手拿到试卷,共有n道选择题,编号为1到n。第i道题形如:(hi为“A”或“B”或“C”或“D”,ai,bi,ci,di都是整数)i.编号小于...

    02015年1月18日1,329构造
  • 「codechef」January Challenge 2015

    「codechef」January Challenge 2015

    CHEFSTON[crayon-5b519da0c17c4003635828/]GCDQgcd满足区间加法TAT,所以维护前缀和后缀和就好了[crayon-5b519da0c17ce949249760/]SEAVOTE去掉所有0后若∑bi<tot或∑bi>=100+n则无解否则有解[crayon-5b519da0c17d3032787006/]ONEKING按照右端点排序,选择第一个的右端点,删去覆盖其的线段。。。剩下的线段同理[crayon-5b519da0c17d7019644435/]CLPERM答案根据第一个不能合成的数奇偶性得...

  • 「CF477B」Dreamoon and Sets

    「CF477B」Dreamoon and Sets

    Dreamoonlikestoplaywithsets,integersand.isdefinedasthelargestpositiveintegerthatdividesbothaandb.LetSbeasetofexactlyfourdistinctintegersgreaterthan0.DefineStobeofrankkifandonlyifforallpairsofdistinctelementssi,sjfromS,.Givenkandn,Dreamoonwantstomakeupnsetsofrankkusingintegersfrom1tomsuchthatnointegerisusedintwodifferentsets(ofcourseyoucanleavesomeintegerswithoutuse).Calculatetheminimummth...

    02014年10月13日1,969构造
  • 「CF459C」Pashmak and Buses

    「CF459C」Pashmak and Buses

    RecentlyPashmakhasbeenemployedinatransportationcompany.Thecompanyhas k busesandhasacontractwithaschoolwhichhas n students.Theschoolplannedtotakethestudentsto d differentplacesfor d days(eachdayinoneplace).Eachdaythecompanyprovidesallthebusesforthetrip.Pashmakhastoarrangethestudentsinthebuses.Hewantstoarrangethestudentsinawaythatnotwostudentsbecomeclosefriends.Inhisridiculousidea,tw...

    02014年8月16日1,677构造
  • 「CF452B」4 – point polyline

    「CF452B」4 - point polyline

    Youaregivenarectangulargridoflatticepointsfrom (0, 0) to (n, m) inclusive.Youhavetochooseexactly4differentpointstobuildapolylinepossiblywithself-intersectionsandself-touching.Thispolylineshouldbeaslongaspossible.Apolylinedefinedbypoints p1, p2, p3, p4 consistsofthelinesegments p1 p2, p2 p3, p3 p4,anditslengthisthesumofthelengthsoftheindividuallinesegments.InputTheonlylineoft...

    02014年7月28日1,333构造
  • 「CF439C」Devu and Partitioning of the Array

    「CF439C」Devu and Partitioning of the Array

    Devubeingasmallkid,likestoplayalot,butheonlylikestoplaywitharrays.Whileplayinghecameupwithaninterestingquestionwhichhecouldnotsolve,canyoupleasesolveitforhim?Givenanarrayconsistingofdistinctintegers.Isitpossibletopartitionthewholearrayinto k disjointnon-emptypartssuchthat p ofthepartshaveevensum(eachofthemmusthaveevensum)andremaining k - p haveoddsum?(notethatpartsneednottobecontinuous...

    02014年6月5日1,637构造
  • 「CF430A」POInts and Segments(easy)

    「CF430A」POInts and Segments(easy)

    Iahubisn'twellpreparedongeometryproblems,butheheardthatthisyeartherewillbealotofgeometryproblemsontheIOIselectioncamp.Scared,Iahublockedhimselfinthebasementandstartedthinkingofnewproblemsofthiskind.Oneofthemisthefollowing.Iahubwantstodraw n distinctpointsand m segmentsonthe OX axis.Hecandraweachpointwitheitherredorblue.Thedrawingisgoodifandonlyifthefollowingrequirementismet:forea...

    02014年5月12日1,683构造
  • 「CF415C」Mashmokh and Numbers

    「CF415C」Mashmokh and Numbers

    It'sholiday.Mashmokhandhisboss,Bimokh,areplayingagameinventedbyMashmokh.InthisgameMashmokhwritessequenceof n distinctintegersontheboard.ThenBimokhmakesseveral(possiblyzero)moves.Onthefirstmoveheremovesthefirstandthesecondintegerfromfromtheboard,onthesecondmoveheremovesthefirstandthesecondintegeroftheremainingsequencefromtheboard,andsoon.Bimokhstopswhentheboardcontainslessthantwonumbers...

    02014年4月7日1,915构造,筛法
2 / 2 « 上一页 1 2