数据描述课件.pptVIP

  • 6
  • 0
  • 约2.94万字
  • 约 130页
  • 2019-01-21 发布于湖北
  • 举报
优化:作为Chain类的成员函数 // distribute to bins for (; first; first = first-link) {// add to bin b = first-data; if (bottom[b]) {// bin not empty top[b]-link = first; top[b] = first;} else // bin empty bottom[b] = top[b] = first; } Delete、Insert调用变为对链表内部结构的直接操纵 旧版本:Delete——delete Insert——new 新版本:节点从原链表摘除,直接放入箱子链表 优化:作为Chain类的成员函数 // collect from bins into sorted chain ChainNodeT *y = 0; for (b = 0; b = range; b++) if (bottom[b]) {// bin not empty if (y) // not first nonempty bin y-link = bottom[b]; else // fi

文档评论(0)

1亿VIP精品文档

相关文档