2018年12月的全部文章
@kidultff

PAT-A 真题 – 1131 Subway Map

In the big cities, the subway systems always look so complex to the visitors. To give you some sense, the following figure shows the map of Beijing subway. Now you are supposed to help people with your computer skills! Given the ...
  • 0
  • 2
@kidultff

PAT-A 真题 – 1130 Infix Expression

Given a syntax tree (binary), you are supposed to output the corresponding infix expression, with parentheses reflecting the precedences of the operators.Input Specification:Each input file contains one test case. For each case, ...
  • 0
  • 2
@kidultff

PAT-A 真题 – 1128 N Queens Puzzle

The "eight queens puzzle" is the problem of placing eight chess queens on an 8×8 chessboard so that no two queens threaten each other. Thus, a solution requires that no two queens share the same row, column, o ...
  • 0
  • 2
@kidultff

C++algorithm中可提高编程效率的几个算法函数

binary_search:二分查找lower_bound:通过二分查找,返回容器中第一个大于或等于n的位置upper_bound:通过二分查找,返回容器中第一个大于n的位置copy:容器拷贝count:通过等于运算符计算容器中特定元素出现次数。(对于struct等,可以重载等于 ...
  • 0
  • 7