20162314 《Program Design & Data Structures》Learning Summary Of The Ninth Week
20162314 2017-2018-1 《Program Design & Data Structures》Learning Summary Of The Ninth Week
Summary of Key Concepts
A heap is a complete binary tree in which each element is greater than or equal to both of its children.
Adding an element to a heap can be accomplished by adding the element as a leaf, then moving it upward as appropriate.
Removing the maximum element from the heap can be accomplished by replacing the root with the last leaf, then moving it downward as appropriate.
A heap sort makes use of the primary characteristic of a heap to sort a set of elements.
A priority queue is not a FIFO queue. It orders elements according to priority,independent of the order in which they are added to the queue.
Problem and solution in teaching materials.
What is the difference between a heap and a binary search tree?
- A binary search tree and a heap are both binary trees that have constraints on the relationships among their elements. The nodes in a binary search tree are less than their left child and
- greater than or equal to their right child, whereas the nodes in a heap (maxheap) are greater than or equal to both children.
What is the difference between a minheap and a maxheap?
- A minheap keeps the smallest value in the tree at the root,whereas a maxheap keeps the largest value at the root.
- Otherwise, their strategies and implementations are similar.
How is the largest element removed from a heap?
- The maximum element is removed from a heap (maxheap) by replacing the root with the last leaf of the tree, then moving that
- element down the tree as appropriate to reassert the proper relationships among the elements.
Code hosting

Summary of error for last week.
Linear search is always more effective than binary search.The answer should be false, for the situation of "n = 2".
Evaluate for my partner
- Advantage and problem in the blog:
- Concise and comprehensie
- Uncleary to the content
- Mould is amazing
- Advantage and problem in the code:
- Serious writing.
- Wonderful idea
- Too less
Learning situation of partner
- Learning content of partner:
- Algorithm
- Recursion
- HanoiTowers and maze
Anything else that want to say
- It's not easy to persere on utizing English to write a blog.But I'm getting used to doing this because of the benefit.
Academic progress check
| Code line number(increasing/accumulative) | Blog number(inc/acc) | studying time(inc/acc) | progress | |
|---|---|---|---|---|
| target | 5000lines | 30articles | 400hours | |
| First week | 180/180 | 1/1 | 20/20 | |
| Second week | 1049/1229 | 1/2 | 18/38 | |
| Third week | 1037/2266 | 3/7 | 22/60 | |
| Fourth week | 1120/3386 | 2/9 | 30/90 |
20162314 《Program Design & Data Structures》Learning Summary Of The Ninth Week的更多相关文章
- 20162314 《Program Design & Data Structures》Learning Summary Of The Seventh Week
20162314 2017-2018-1 <Program Design & Data Structures>Learning Summary Of The Seventh Wee ...
- 20162314 《Program Design & Data Structures》Learning Summary Of The Fifth Week
20162314 2017-2018-1 <Program Design & Data Structures>Learning Summary Of The Fifth Week ...
- 20162314 《Program Design & Data Structures》Learning Summary Of The Second Week
20162314 2017-2018-1 <Program Design & Data Structures>Learning Summary Of The Second Week ...
- 20162314 《Program Design & Data Structures》Learning Summary Of The First Week
20162314 2017-2018-1 <Program Design & Data Structures>Learning Summary Of The First Week ...
- 20162314 《Program Design & Data Structures》Learning Summary Of The Eleventh Week
20162314 2017-2018-1 <Program Design & Data Structures>Learning Summary Of The Eleventh We ...
- 20162314 《Program Design & Data Structures》Learning Summary Of The Tenth Week
20162314 2017-2018-1 <Program Design & Data Structures>Learning Summary Of The Tenth Week ...
- 20162314 《Program Design & Data Structures》Learning Summary Of The Eighth Week
20162314 2017-2018-1 <Program Design & Data Structures>Learning Summary Of The Eighth Week ...
- 20182320《Program Design and Data Structures》Learning Summary Week9
20182320<Program Design and Data Structures>Learning Summary Week9 1.Summary of Textbook's Con ...
- 【Python学习笔记】Coursera课程《Python Data Structures》 密歇根大学 Charles Severance——Week6 Tuple课堂笔记
Coursera课程<Python Data Structures> 密歇根大学 Charles Severance Week6 Tuple 10 Tuples 10.1 Tuples A ...
随机推荐
- FFMpeg笔记(一) 使用FFmpeg将任意格式图片转换成任意格式图片
void SrcToDest(char* pSrc, char* pDest,unsigned int nSrcWidth, unsigned int nSrcHeight, AVPixelForma ...
- Mysql5.7.21 Navicat触发器创建
CREATE TRIGGER m_trigger AFTER UPDATE ON table1 FOR EACH ROW BEGIN IF( old.status!= new.status) THEN ...
- Redis全方位讲解--主从复制
前言 前面介绍了redis持久化和容灾备份,这篇会介绍redis主从复制和redis持久化在主从复制中的一些应用.因为本人没有那么多服务器或机器,所以这里主要介绍下如何在docker容器中搭建主从复制 ...
- SEO优化上首页之搜索引擎蜘蛛Spider原理
Spider,蜘蛛,又名网页网络爬虫.网络机器人,是按照一定策略不断抓取互联网网页的特定程序.蜘蛛抓回的页面创建索引后参与排名,等待用户检索.为了网站优化自然排名上首页,精灵儿工作室下面详细剖析Spi ...
- docker 下 mysql 集群的搭建
下载程序&&创建docker容器 从mysql官网https://dev.mysql.com/downloads/cluster/上下载mysql集群库mysql-cluster-gp ...
- Scratch 3.0 版本比较
新年伊始MIT 就正式 发布了Scratch最新3.0版 ,以 HTML5.0 为基础的版本! 本文就来带看看3.0版有哪些更新的地方. 下图是进入后第一个画面,跟Scratch 2.0 很像,熟悉的 ...
- SFTP Using Chilkat Active component
https://www.example-code.com/vb6/sftp_uploadBandwidthThrottle.asp Private Sub Command1_Click() ' Imp ...
- 2017-2018-1 20155226 《信息安全系统设计基础》课下实践——实现mypwd
2017-2018-1 20155226 <信息安全系统设计基础>课下实践--实现mypwd 1 学习pwd命令 输入pwd命令 发现他是给出当前文件夹的绝对路径. 于是 man 1 pw ...
- 2017-2018-1 20155231 课堂测试 (ch06)
2017-2018-1 20155231 课堂测试 (ch06) 1 (单选题|1分) 下面代码中,对数组x填充后,采用直接映射高速缓存,所有对x和y引用的命中率为(D) A .1 B .1/4 C ...
- [HNOI2012]永无乡 线段树合并
[HNOI2012]永无乡 LG传送门 线段树合并练手题,写这篇博客只是为了给我的这篇文章找个板子题. 并查集维护连通性,对于不在同一个连通块内的合并操作每次直接合并两颗线段树,复杂度\(O(n \l ...


