亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? 1794 -- castle walls.htm

?? 一道很好的acm題目
?? HTM
字號:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- saved from url=(0061)http://acm.pku.edu.cn/JudgeOnline/showproblem?problem_id=1794 -->
<HTML><HEAD><TITLE>1794 -- Castle Walls</TITLE>
<META http-equiv=Pragma content=no-cache>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<STYLE type=text/css>A {
	TEXT-DECORATION: none
}
A:hover {
	COLOR: red; TEXT-DECORATION: underline
}
</STYLE>

<META content="MSHTML 6.00.2900.2722" name=GENERATOR></HEAD>
<BODY vLink=blue aLink=blue link=blue leftMargin=5><A name=top></A>
<TABLE style="BORDER-COLLAPSE: collapse" borderColor=#ffffff width=980 
  border=1><TBODY>
  <TR>
    <TD align=middle colSpan=5><IMG height=97 
      src="1794 -- Castle Walls.files/logo.jpg" width=980 border=0></TD></TR>
  <TR vAlign=top align=middle bgColor=#6589d1>
    <TH width=196>Online Judge</TH>
    <TH width=196>Problem Set</TH>
    <TH width=196>Authors</TH>
    <TH width=197>Online Contests</TH>
    <TH width=197>User</TH></TR>
  <TR vAlign=top align=middle bgColor=#f1f1fd>
    <TD><A href="http://acm.pku.edu.cn/JudgeOnline/bbs">Web Board</A><BR><A 
      href="http://acm.pku.edu.cn/JudgeOnline/">Home Page</A><BR><A 
      href="http://acm.pku.edu.cn/JudgeOnline/faq.htm" 
      target=_blank>F.A.Qs</A><BR>Announcement</TD>
    <TD>
      <FORM action=gotoproblem method=get><A 
      href="http://acm.pku.edu.cn/JudgeOnline/problemlist">Problems</A><BR><A 
      href="http://acm.pku.edu.cn/JudgeOnline/submitpage">Submit 
      Problem</A><BR><A href="http://acm.pku.edu.cn/JudgeOnline/status">Status 
      (Online)</A><BR><FONT color=blue>Prob.ID:</FONT><INPUT size=6 name=pid><INPUT type=submit value=Go name=pb1></FORM></TD>
    <TD>
      <FORM action=searchuser method=get><A 
      href="http://acm.pku.edu.cn/JudgeOnline/registerpage">Register</A><BR><A 
      href="http://acm.pku.edu.cn/JudgeOnline/modifyuserpage">Update your 
      info</A><BR><A href="http://acm.pku.edu.cn/JudgeOnline/userlist">Authors 
      ranklist</A><BR><INPUT size=10 name=user_id><INPUT type=submit value=Search name=B1></FORM></TD>
    <TD><FONT color=#1a5cc8>Current Contest</FONT><BR><A 
      href="http://acm.pku.edu.cn/JudgeOnline/pastcontests">Past 
      Contests</A><BR><A 
      href="http://acm.pku.edu.cn/JudgeOnline/contests">Scheduled 
      Contests</A><BR><A 
      href="http://acm.pku.edu.cn/JudgeOnline/awardcontest_announce.htm" 
      target=_blank><FONT color=red>Award Contest</FONT></A></TD>
    <TD align=left><IFRAME border=0 align=middle 
      src="1794 -- Castle Walls.files/login.htm" frameBorder=0 width=197 
      scrolling=no height=90></IFRAME></TD></TR></TBODY></TABLE>
<TABLE width="100%" background="1794 -- Castle Walls.files/table_back.jpg" 
border=0>
  <TBODY>
  <TR>
    <TD>
      <P align=center><FONT color=blue size=5>Castle Walls</FONT></P>
      <P align=center>Time Limit:1000MS&nbsp; Memory Limit:30000K<BR>Total 
      Submit:404 Accepted:110 </P><B><FONT color=#333399 
      size=5>Description</FONT></B> 
      <P><FONT face="Times New Roman" size=3>Background <BR>In medieval times, 
      knights commanded big armies of peasants. When they had to storm a castle 
      they would line up neatly in front of the castle's wall and throw their 
      grappling hooks over the walls. If one does not throw straight it can 
      easily happen that two hooks cross, making it impossible for the two 
      peasants to climb the wall. That's why every knight made his peasants 
      practice a lot so that this would not happen in combat. <BR>Due to the 
      recent Sir Arthur-Madam Claire Marriage (ACM), two peasant armies have to 
      be merged. <BR>Traditionally Sir Arthur's peasants wear blue and Madame 
      Claire's peasants wear red. When practicing together, both armies mix up 
      in front of a castle's wall. On Sir Arthur's command, they all throw their 
      grappling hooks. Due to their perfect training the hooks will never cross 
      within an army, however it can happen that a hook thrown by a blue peasant 
      crosses one thrown by a peasant of the red army. <BR>For statistical 
      purposes, Sir Arthur now needs to find out how many grappling hooks have 
      crossed so that he can measure how well their armies have already been 
      merged. <BR>Problem <BR>Given the positions of blue and red peasants as 
      well as the positions they threw their grappling hooks at,determine how 
      many distinct pairs of blue and red peasants crossed their hooks. <BR>If 
      there are n blue and m red peasants, the positions in the line where the 
      peasants are standing are numbered from 1 to n + m. The positions on the 
      castle's wall are numbered from 1 to n + m as well,where position i is 
      directly opposite of position i on the line the peasants are standing on. 
      A grappling hook thrown from position i to j is said to cross another hook 
      thrown from k to l if and only if <BR>(i &lt; k and j &gt;= l) or (i &gt; 
      k and j &lt;= l) <BR>Grappling hooks of the same color will never cross 
      each other, nor will two peasants occupy the same position on the line. 
      However, two hooks (of different color) can be thrown to the same position 
      in which case they are said to cross each other as 
      well.</FONT></P><B><FONT color=#333399 size=5>Input</FONT></B> 
      <P><FONT face="Times New Roman" size=3>The first line contains the number 
      of scenarios. <BR>In each scenario, you are first given a line with two 
      integers n and m, the number of blue and red peasants, respectively (1 
      &lt;= n,m &lt;= 30 000). <BR>The next n lines describe the blue peasants 
      followed by m more lines for the red peasants. Each line consists of two 
      integer i and j separated by a space, indicating the peasant's position i 
      and the position j he threw his grappling hook to (1 &lt;= i, j &lt;= n + 
      m).</FONT></P><B><FONT color=#333399 size=5>Output</FONT></B> 
      <P><FONT face="Times New Roman" size=3>For each scenario first output a 
      line "Scenario #i:" where i is the number of the scenario starting with 1, 
      followed by a line containing the number of distinct pairs of peasants 
      whose grappling hooks are crossed,and print a blank line at the end of 
      each scenario.</FONT></P><B><FONT color=#333399 size=5>Sample 
      Input</FONT></B> 
      <P><FONT face="Times New Roman" size=3><PRE>2
2 2
1 2
3 4
2 1
4 3
2 3
1 3
2 5
5 3
3 1
4 2</PRE></FONT>
      <P></P><B><FONT color=#333399 size=5>Sample Output</FONT></B> 
      <P><FONT face="Times New Roman" size=3><PRE>Scenario #1:
2

Scenario #2:
6
</PRE></FONT>
      <P></P><B><FONT color=#333399 size=5>Source</FONT></B> 
      <P><FONT face="Times New Roman" size=3>TUD Programming Contest 2004, 
      Darmstadt, Germany</FONT></P></TD></TR></TBODY></TABLE><FONT color=#333399 
size=3>
<P align=center>[<A 
href="http://acm.pku.edu.cn/JudgeOnline/submitpage?problem_id=1794">Submit</A>]&nbsp;&nbsp; 
[<A href="javascript:history.go(-1)">Go Back</A>]&nbsp;&nbsp; [<A 
href="http://acm.pku.edu.cn/JudgeOnline/problemstatus?problem_id=1794">Status</A>]&nbsp;&nbsp; 
[<A href="http://acm.pku.edu.cn/JudgeOnline/bbs?problem_id=1794">Discuss</A>] 
</FONT></P>
<P><IMG height=29 src="1794 -- Castle Walls.files/home.jpg" width=40 
border=0><FONT size=3><A href="http://acm.pku.edu.cn/JudgeOnline/">Home Page</A> 
</FONT>&nbsp;&nbsp;<IMG height=29 src="1794 -- Castle Walls.files/goback.jpg" 
width=40 border=0><FONT size=3><A href="javascript:history.go(-1)">Go 
Back</A>&nbsp;&nbsp;<IMG height=29 src="1794 -- Castle Walls.files/top.jpg" 
width=40 border=0><A 
href="http://acm.pku.edu.cn/JudgeOnline/showproblem?problem_id=1794#top">To 
top</A></FONT><BR>
<HR>

<P align=center><FONT size=3>All Copyright Reserved 2003-2005 Ying Fuchen,Xu 
Pengcheng<BR>Any problem, Please <A href="mailto:hawking@pku.edu.cn">Contact 
Administrator</A></FONT></P></BODY></HTML>

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久免费精品国产久精品久久久久| 欧美不卡一区二区三区| 美腿丝袜亚洲一区| 中文字幕一区免费在线观看| 777欧美精品| 91成人在线精品| 国产ts人妖一区二区| 天天综合网 天天综合色| 国产精品国产三级国产a| 欧美sm美女调教| 欧美日韩一区高清| 91丝袜呻吟高潮美腿白嫩在线观看| 青青草原综合久久大伊人精品优势| 亚洲欧美怡红院| 中文字幕av资源一区| 7777女厕盗摄久久久| 色婷婷久久99综合精品jk白丝| 国产不卡视频一区| 国产伦精一区二区三区| 免费成人av在线| 亚洲国产成人91porn| 亚洲美女免费视频| 国产精品美女www爽爽爽| 久久蜜桃av一区精品变态类天堂| 日韩视频在线观看一区二区| 欧洲生活片亚洲生活在线观看| www.欧美.com| 成人国产电影网| 成人中文字幕合集| 国产91精品免费| 国产宾馆实践打屁股91| 国产91色综合久久免费分享| 国产精品影音先锋| 国产一区二区成人久久免费影院| 美女在线视频一区| 久久精品国产99国产| 美女任你摸久久| 麻豆国产欧美日韩综合精品二区| 麻豆高清免费国产一区| 麻豆精品久久久| 国产精品综合一区二区| 国产一本一道久久香蕉| 国产高清亚洲一区| 国产成人高清视频| 成人性生交大合| av资源站一区| 色欧美日韩亚洲| 欧美三区在线视频| 久久久91精品国产一区二区三区| 欧美一级在线视频| 久久综合九色综合97婷婷女人| 久久久美女毛片| 国产精品伦理一区二区| 亚洲日本va午夜在线影院| 亚洲日本韩国一区| 午夜av电影一区| 久久99久久精品| 国产成人精品免费| 在线看国产一区二区| 欧美日本韩国一区| 精品国产不卡一区二区三区| 国产亚洲视频系列| 亚洲人妖av一区二区| 香蕉av福利精品导航| 久久成人av少妇免费| 国产aⅴ精品一区二区三区色成熟| 成人精品高清在线| 精品视频在线免费观看| 精品久久一区二区| 国产精品色婷婷久久58| 午夜视黄欧洲亚洲| 国产精品综合av一区二区国产馆| 99视频一区二区三区| 欧美精品在线一区二区| 久久精品人人做人人综合| 亚洲免费观看高清完整版在线观看 | 精品一区二区综合| 成人黄色小视频| 欧美日韩激情一区| 国产色产综合色产在线视频| 亚洲综合免费观看高清在线观看| 免费成人美女在线观看.| eeuss鲁一区二区三区| 91精品国产综合久久精品性色| 国产日韩精品一区二区三区| 一区二区在线电影| 国产91精品在线观看| 欧美丰满少妇xxxxx高潮对白| 国产喷白浆一区二区三区| 亚洲一线二线三线久久久| 国产精品一线二线三线| 欧美丝袜丝交足nylons| 国产精品美女久久久久av爽李琼 | 欧美日韩在线播放| 中文字幕欧美激情一区| 日本不卡123| 99久久777色| 久久亚洲一区二区三区四区| 亚洲午夜电影网| 99re这里只有精品6| 精品处破学生在线二十三| 亚洲一卡二卡三卡四卡无卡久久 | 国产日韩欧美精品一区| 日韩激情视频网站| 色国产精品一区在线观看| 久久久综合视频| 裸体一区二区三区| 欧美日韩一区二区三区在线看 | 久久精品噜噜噜成人av农村| 在线观看不卡一区| 中文字幕日韩av资源站| 国产馆精品极品| 精品国免费一区二区三区| 午夜天堂影视香蕉久久| 91免费小视频| 国产精品超碰97尤物18| 国产精品一区二区你懂的| 日韩美女视频一区二区在线观看| 亚洲狠狠爱一区二区三区| 青青草精品视频| 在线综合+亚洲+欧美中文字幕| 亚洲激情成人在线| 日本久久电影网| 国产精品久久久久久久蜜臀| 国产乱人伦偷精品视频免下载| 欧美r级电影在线观看| 蜜桃久久av一区| 欧美va亚洲va在线观看蝴蝶网| 日韩成人免费看| 欧美一区二区三区白人| 日日噜噜夜夜狠狠视频欧美人 | 精品国产凹凸成av人导航| 美女脱光内衣内裤视频久久网站| 欧美精品乱码久久久久久| 亚洲二区在线观看| 6080午夜不卡| 蜜桃传媒麻豆第一区在线观看| 日韩亚洲欧美在线观看| 老司机免费视频一区二区三区| 日韩欧美的一区| 国内成+人亚洲+欧美+综合在线| 精品国产91九色蝌蚪| 国产麻豆欧美日韩一区| 国产日产精品一区| 成人黄色片在线观看| 亚洲色图在线看| 欧美日韩在线播放一区| 美女一区二区三区在线观看| 日韩欧美一级二级| 国产成人啪免费观看软件| 国产精品灌醉下药二区| 色av综合在线| 午夜精品久久一牛影视| 日韩欧美成人一区| 国产精品77777| 亚洲精品视频自拍| 91精品国产综合久久蜜臀| 久久爱另类一区二区小说| 久久久国产精品麻豆| 99re这里只有精品6| 亚洲成在人线免费| 久久色视频免费观看| 成人av动漫网站| 亚洲尤物在线视频观看| 精品国产一区二区三区忘忧草 | 在线观看日韩高清av| 免费在线观看成人| 国产欧美视频在线观看| 色婷婷国产精品综合在线观看| 日日摸夜夜添夜夜添国产精品 | 欧美无砖砖区免费| 久久99精品久久久久久国产越南 | 国产精品一区二区在线观看不卡| 国产精品伦理在线| 777色狠狠一区二区三区| 高清不卡在线观看| 亚洲国产一区二区a毛片| 久久久久久99久久久精品网站| 在线观看亚洲专区| 国产一区二区女| 亚洲一级在线观看| 中文天堂在线一区| 7777精品伊人久久久大香线蕉经典版下载 | 日韩av一级电影| 国产精品私人影院| 91精品国产综合久久久蜜臀粉嫩| 国产98色在线|日韩| 日本免费在线视频不卡一不卡二| 国产精品欧美一区喷水| 欧美一级欧美三级| 色香蕉成人二区免费| 美国av一区二区| 亚洲国产va精品久久久不卡综合| 欧美精品一区二区三区高清aⅴ | 久久精品综合网| 91精品欧美久久久久久动漫| av一区二区不卡| 美国欧美日韩国产在线播放| 亚洲一区二区三区激情| 中日韩免费视频中文字幕|