标准库
智渊
这个作者很懒,什么都没留下…
展开
-
set 的用法
简介:set是一个去除掉数组中重复元素并进行排序的集合,学过python的同学应该知道python里面的set类,不一样的地方在于C++类库的set会自动将数组进行排序。如果需要只进行排序当不进行去重,则使用multiset;如果只去重不排序则使用unorder_set;类型名 作用 头文件 set<elemType>name 去重并且排序 ...原创 2018-08-05 10:17:23 · 295 阅读 · 0 评论 -
PAT A 1060 Are They Equal (25)(25 分)
题目介绍:If a machine can save only 3 significant digits, the float numbers 12300 and 12358.9 are considered equal since they are both saved as 0.123*10^5^ with simple chopping. Now given the number of ...原创 2018-08-05 23:25:58 · 442 阅读 · 3 评论 -
PAT A1032 Sharing (25)(25 分)
题目描述:To store English words, one method is to use linked lists and store a word letter by letter. To save some space, we may let the words share the same sublist if they share the same suffix. For e...原创 2018-08-06 16:16:41 · 141 阅读 · 0 评论 -
PAT A1002 A+B for Polynomials(25 分)
题目要求:This time, you are supposed to find A+B where A and B are two polynomials.Input Specification:Each input file contains one test case. Each case occupies 2 lines, and each line contains the ...原创 2018-09-10 10:34:02 · 265 阅读 · 0 评论