摘要: 前缀表达式:op a b 中缀表达式:a op b 后缀表达式 a b op 1、对于计算单独的后缀表达式较为简单,从左到右,遇到数字将其压入栈内,遇到操作符从栈中取出两个数进行相应操作,结果再次压入栈内。 2、对于前缀表达式的计算和后缀相似,从右到左的顺序,剩下和后缀一致 3、对于中缀表达式,我们 阅读全文
posted @ 2019-03-31 15:44 进击的黑仔 阅读(1329) 评论(0) 推荐(0)
摘要: Description The Leiden University Library has millions of books. When a student wants to borrow a certain book, he usually submits an online loan form 阅读全文
posted @ 2019-03-29 23:03 进击的黑仔 阅读(191) 评论(0) 推荐(0)
摘要: The 15-puzzle has been around for over 100 years; even if you don't know it by that name, you've seen it. It is constructed with 15 sliding tiles, eac 阅读全文
posted @ 2019-03-28 19:22 进击的黑仔 阅读(217) 评论(0) 推荐(0)
摘要: "Good man never makes girls wait or breaks an appointment!" said the mandarin duck father. Softly touching his little ducks' head, he told them a stor 阅读全文
posted @ 2019-03-27 19:18 进击的黑仔 阅读(267) 评论(0) 推荐(0)
摘要: Last night, little erriyue had a horrible nightmare. He dreamed that he and his girl friend were trapped in a big maze separately. More terribly, ther 阅读全文
posted @ 2019-03-27 14:20 进击的黑仔 阅读(266) 评论(0) 推荐(0)
摘要: After going through the receipts from your car trip through Europe this summer, you realised that the gas prices varied between the cities you visited 阅读全文
posted @ 2019-03-26 20:27 进击的黑仔 阅读(167) 评论(0) 推荐(0)
摘要: 描述 Ha'nyu是来自异世界的魔女,她在漫无目的地四处漂流的时候,遇到了善良的少女Rika,从而被收留在地球上。Rika的家里有一辆飞行车。有一天飞行车的电路板突然出现了故障,导致无法启动。 电路板的整体结构是一个R行C列的网格(R,C≤500),如右图所示。每个格点都是电线的接点,每个格子都包含 阅读全文
posted @ 2019-03-25 18:13 进击的黑仔 阅读(1090) 评论(0) 推荐(0)
摘要: Description A Sudoku grid is a 16x16 grid of cells grouped in sixteen 4x4 squares, where some cells are filled with letters from A to P (the first 16 阅读全文
posted @ 2019-03-25 09:37 进击的黑仔 阅读(400) 评论(0) 推荐(0)
摘要: Imagine you are standing inside a two-dimensional maze composed of square cells which may or may not be filled with rock. You can move north, south, e 阅读全文
posted @ 2019-03-25 08:56 进击的黑仔 阅读(338) 评论(0) 推荐(0)
摘要: 描述 给定一个N行M列的01矩阵 A,A[i][j] 与 A[k][l] 之间的曼哈顿距离定义为: dist(A[i][j],A[k][l])=|i-k|+|j-l| 输出一个N行M列的整数矩阵B,其中: B[i][j]=min(1≤x≤N,1≤y≤M,A[x][y]=1)⁡{dist(A[i][j 阅读全文
posted @ 2019-03-24 19:52 进击的黑仔 阅读(425) 评论(0) 推荐(0)