• 「BZOJ1687」[Usaco2005 Open] Navigating the City 城市交通

    「BZOJ1687」[Usaco2005 Open] Navigating the City 城市交通

    Description    由于牛奶市场的需求,奶牛必须前往城市,但是唯一可用的交通工具是出租车.教会奶牛如何在城市里打的.    给出一个城市地图,东西街区E(1≤E≤40),南北街区N(1≤N≤30).制作一个开车指南给出租车司机,告诉他如何从起点(用S表示)到终点(用E表示).每一个条目用空格分成两部分,第一个部分是方向(N,E,S,W之一),第二个是一个整数,表示要沿着这个方向开几个十字路口.如果存在多条路线...

    02014年4月15日3,533广度搜索
  • 「POJ1265」Area

    「POJ1265」Area

    DescriptionBeingwellknownforitshighlyinnovativeproducts,Merckwoulddefinitelybeagoodtargetforindustrialespionage.Toprotectitsbrand-newresearchanddevelopmentfacilitythecompanyhasinstalledthelatestsystemofsurveillancerobotspatrollingthearea.Theserobotsmovealongthewallsofthefacilityandreportsuspiciousobservationstothecentralsecurityoffice.Theonlyflawinthesystemacompetitor抯agentcouldfindisthefac...

    02014年4月14日3,992几何
  • 「POJ2954」Triangle

    「POJ2954」Triangle

    DescriptionA latticepoint isanorderedpair(x, y)where x and y arebothintegers.Giventhecoordinatesoftheverticesofatriangle(whichhappentobelatticepoints),youaretocountthenumberoflatticepointswhichliecompletelyinsideofthetriangle(pointsontheedgesorverticesofthetriangledonotcount).InputTheinputtestfilewillcontainmultipletestcases.Eachinputtestcaseconsistsofsixintegers x1, y1, x2, y2, ...

    02014年4月14日3,280几何
  • 「POJ1654」Area

    「POJ1654」Area

    DescriptionYouaregoingtocomputetheareaofaspecialkindofpolygon.Onevertexofthepolygonistheoriginoftheorthogonalcoordinatesystem.Fromthisvertex,youmaygostepbysteptothefollowingvertexesofthepolygonuntilbacktotheinitialvertex.ForeachstepyoumaygoNorth,West,SouthorEastwithsteplengthof1unit,orgoNorthwest,Northeast,SouthwestorSoutheastwithsteplengthofsquarerootof2.Forexample,thisisalegalpolyg...

    02014年4月14日2,759几何
  • 「POJ1039」Pipe

    「POJ1039」Pipe

    DescriptionTheGXLightPipelineCompanystartedtopreparebentpipesforthenewtransgalacticlightpipeline.Duringthedesignphaseofthenewpipeshapethecompanyranintotheproblemofdetermininghowfarthelightcanreachinsideeachcomponentofthepipe.Notethatthematerialwhichthepipeismadefromisnottransparentandnotlightreflecting.Eachpipecomponentconsistsofmanystraightpipesconnectedtightlytogether.Fortheprogrammin...

    02014年4月14日2,955几何
  • 「POJ2826」An Easy Problem?!

    「POJ2826」An Easy Problem?!

    DescriptionIt'srainingoutside.FarmerJohnson'sbullBenwantssomeraintowaterhisflowers.Bennailstwowoodenboardsonthewallofhisbarn.Showninthepicturesbelow,thetwoboardsonthewalljustlookliketwosegmentsontheplane,astheyhavethesamewidth.Yourmissionistocalculatehowmuchrainthesetwoboardscancollect.InputThefirstlinecontainsthenumberoftestcases.Eachtestcaseconsistsof8integersnotexceeding10,000byabsol...

    02014年4月14日5,641几何
  • 「BZOJ1391」[Ceoi2008] order

    「BZOJ1391」[Ceoi2008] order

    Description有N个工作,M种机器,每种机器你可以租或者买过来.每个工作包括若干道工序,每道工序需要某种机器来完成,你可以通过购买或租用机器来完成。现在给出这些参数,求最大利润Input第一行给出N,M(1<=N<=1200,1<=M<=1200)下面将有N块数据,每块数据第一行给出完成这个任务能赚到的钱(其在[1,5000])及有多少道工序接下来若干行每行两个数,分别描述完成工序所需要的机器编号及租用它的费用(其在[1,20000]...

    42014年4月13日5,253最小割
  • 「POJ1410」Intersection

    「POJ1410」Intersection

    DescriptionYouaretowriteaprogramthathastodecidewhetheragivenlinesegmentintersectsagivenrectangle.Anexample:line:startpoint:(4,9)endpoint:(11,2)rectangle:left-top:(1,5)right-bottom:(7,1)Figure1:LinesegmentdoesnotintersectrectangleThelineissaidtointersecttherectangleifthelineandtherectanglehaveatleastonepointincommon.Therectangleconsistsoffourstraightlinesandtheareainbetween.Althoughallinput...

    02014年4月13日3,885几何
  • 「POJ1066」Treasure Hunt

    「POJ1066」Treasure Hunt

    DescriptionArcheologistsfromtheAntiquitiesandCuriosMuseum(ACM)haveflowntoEgypttoexaminethegreatpyramidofKey-Ops.Usingstate-of-the-arttechnologytheyareabletodeterminethatthelowerfloorofthepyramidisconstructedfromaseriesofstraightlinewalls,whichintersecttoformnumerousenclosedchambers.Currently,nodoorsexisttoallowaccesstoanychamber.Thisstate-of-the-arttechnologyhasalsopinpointedthelocat...

    02014年4月12日3,748几何
  • 「POJ1556」The Doors

    「POJ1556」The Doors

    DescriptionYouaretofindthelengthoftheshortestpaththroughachambercontainingobstructingwalls.Thechamberwillalwayshavesidesatx=0,x=10,y=0,andy=10.Theinitialandfinalpointsofthepatharealways(0,5)and(10,5).Therewillalsobefrom0to18verticalwallsinsidethechamber,eachwithtwodoorways.Thefigurebelowillustratessuchachamberandalsoshowsthepathofminimallength.InputTheinputdatafortheillustratedchamberwould...

    02014年4月12日5,593spfa,几何
  • 「BZOJ1646」[Usaco2007 Open] Catch That Cow 抓住那只牛

    「BZOJ1646」[Usaco2007 Open] Catch That Cow 抓住那只牛

    DescriptionFarmerJohnhasbeeninformedofthelocationofafugitivecowandwantstocatchherimmediately.HestartsatapointN(0<=N<=100,000)onanumberlineandthecowisatapointK(0<=K<=100,000)onthesamenumberline.FarmerJohnhastwomodesoftransportation:walkingandteleporting.*Walking:FJcanmovefromanypointXtothepointsX-1orX+1inasingleminute*Teleporting:FJcanmovefromanypointXtothepoint2*Xi...

    02014年4月12日2,897广度搜索
  • 「BZOJ1610」[Usaco2008 Feb] Line连线游戏

    「BZOJ1610」[Usaco2008 Feb] Line连线游戏

    DescriptionFarmerJohn最近发明了一个游戏,来考验自命不凡的贝茜。游戏开始的时候,FJ会给贝茜一块画着N(2<=N<=200)个不重合的点的木板,其中第i个点的横、纵坐标分别为X_i和Y_i(-1,000<=X_i<=1,000;-1,000<=Y_i<=1,000)。贝茜可以选两个点画一条过它们的直线,当且仅当平面上不存在与画出直线平行的直线。游戏结束时贝茜的得分,就是她画出的直线的总条数。为了在游戏中胜出,贝茜找到了你,希望你...

    22014年4月12日5,055几何
101 / 144 « 上一页 1 ...99 100 101 102 103 ...144 下一页 »