Chapter6. Data structure

数据结构是计算机中存储,组织数据的方式,精心选择的数据结构可以带来最优效率算法。

C++, Java, Python 等面向对象的编程语言可使用类完成这一功能。现代编程语言及其运行环境在标准库中都包含了多种数据结构,例如C++标准模版库中的容器,Java集合框架以及微软的.NET Framework.

数据结构意味着接口或封装:一个数据结构可被视为两个函数之间的接口,或者是由数据类型联合组成的存储内容的访问方法封装。

Usually, efficient data structures are key to designing efficient algorithms. Some formal design methods and programming languages emphasize data structures, rather than algorithms, as the key organizing factor in software design.

Data structures are generally based on the ability of a computer to fetch and store data at any place in its memory, specified by a pointer--a bit string, representing a memory address, that can be itself stored in memory and manipulated by the program. Thus, the array record data structures are based on computing the addresses of data items with arithmetic operations; while the linked data structures are based on storing addresses of data items within the structure itself. A data structure that is defined indirectly by the operations that may be performed on it, and the mathematical properties of those operations (including their space and time cost).

常见的数据结构:

数组  (Array) 

A array is a number of elements in a specific order, typically all of the same type. Elements are accessed using an

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值