首页 > 其他分享 >Programming Abstractions in C阅读笔记:p327-p330

Programming Abstractions in C阅读笔记:p327-p330

时间:2024-03-20 09:24:30浏览次数:22  
标签:p327 ad form Abstractions assimilate Programming called stack

《Programming Abstractions in C》学习第78天,p327-p330,总计4页。

一、技术总结

1.ADT(抽象数据类型)

p328, A type defined in term of its behavior rather than its represnetation is called an abstract data type(如果一种数据类型使用它们的行为而不是表示来定义,那么这样的数据类型称为抽象数据类型)。

2.stack(栈)

(1)定义

p328, In this section, you will learn about a data structure called a stack, which provides storages for a collection a data values, subject to the restriction that values can only be be removed from a stack in the opposite order from which they were added(栈是一种数据结构。栈用于存储一组数据,并且栈里面的元素只能后进先出)。

(2)相关术语

1)element(元素):The values stored in a stack are called its elements。

2)pushing(入栈) & popping(出栈):Adding a new element to a stack is called pushing that element。Removing the most recent element from a stack is called popping the stack。两者简称为LIFO(后进先出,last in, first out)。

之前总是分不清 push 和 pop,到底哪个是入栈,哪个是出栈。后面是使用联想记忆来记住,push——(press按)/pressure(压力),施加压力,按下去,所以是压入;pop——pop back up(弹回),所以是出栈。

二、英语总结

1.assimilate form是什么意思?

答: in phsiology, "absorb into and make part of the body"(在生理学上,指“吸收并使之称为身体的一部分”)。assimilate form 正是来自此意思,例如:Before a voiced consonant sound, "ad" can assimilate into "a" or "at" in pronunciation(在浊辅音前,"ad" 可以被同化为“a”或者“at”)。从语法上来说,这是指发音的变化。

以assimilate这个单词为例,from assimilated form of ad(to的意思, 即assimilate的首字母a是ad的同化形式) + simulare(make similar之意)。这在语法解释上会见得比较多。

2.assemble是什么意思?

答:

(1)assimulare(from Latin) > assembler(from old French) > assemble。

(2)assimulare: ad-(a from assimilatd form of ad) + simulare(to make like)。sim from stem of similis "like, resembling, of the same kind" (sim 来自于similis的主干部分)。

(3)assemble: vi. collect into one place; vt. meet or come together,聚集,组装。

p328, As you know from your programming experience, data structures can be assembled to form hierarchies.

3.physiology是什么意思?

答:physio-(nature) + -logy(study,研究),science of the normal function of living things(生理学)。

4.occupy是什么意思?

答:ob-(over) + intensive form(强化形式) of capere(to grasp, seize, from PIE root *kap-)。vt. to take possession of and keep (拥有,占有, 占据)。

三、其它

近两周是不那么愉快的一周。工作上,自己在一个项目中投入大量的时间,极速响应,但是却总要等待别人,此时很容易导致自己变得烦躁。因为总感觉自己为项目投入那么多,甚至牺牲一些生活上的时间,但是别人却做不到,项目进度并没有提前,效果也没有变好,就会觉得不值当。

有时候想想,这种想法有一点的主观性,因为不能因为自己这样想,而要求别人一样这样做,可能别人并不想这样做。工作上寻找三观相合的同事确实不是那么容易的一件事,还是保持平常心。

四、参考资料

1. 编程

(1)Eric S.Roberts,《Programming Abstractions in C》:https://book.douban.com/subject/2003414

2. 英语

(1)Etymology Dictionary:https://www.etymonline.com

(2) Cambridage Dictionary:https://dictionary.cambridge.org

欢迎搜索及关注:编程人(a_codists)

标签:p327,ad,form,Abstractions,assimilate,Programming,called,stack
From: https://www.cnblogs.com/codists/p/18084426

相关文章

  • JB Loves Math(The 19th Zhejiang Provincial Collegiate Programming Contest)
    #include<bits/stdc++.h>#defineendl'\n'usingll=longlong;typedefunsignedlonglongull;usingnamespacestd;voidGordenGhost();signedmain(){#ifdefGordenfreopen("in.txt","rt",stdin);freopen......
  • JB Wants to Earn Big Money(The 19th Zhejiang Provincial Collegiate Programming Co
    #include<bits/stdc++.h>#defineendl'\n'usingll=longlong;typedefunsignedlonglongull;usingnamespacestd;voidGordenGhost();signedmain(){#ifdefGordenfreopen("in.txt","rt",stdin);freopen......
  • JB Loves Comma(The 19th Zhejiang Provincial Collegiate Programming Contest)
    #include<bits/stdc++.h>#defineendl'\n'usingll=longlong;typedefunsignedlonglongull;usingnamespacestd;voidGordenGhost();signedmain(){#ifdefGordenfreopen("in.txt","rt",stdin);freopen......
  • [SCOI2011][洛谷P3275] 糖果
    本来这是一道差分约束板子题/水题SPFA-BFS和SPFA-DFS都能过BFS#include<bits/stdc++.h>usingnamespacestd;typedeflonglongll;constllN=100005;#definemax(a,b)((a)>(b)?(a):(b))#definemin(a,b)((a)<(b)?(a):(b))structedge{ intto,next,w;}e[N*1000]......
  • Monoxer Programming Contest 2024(AtCoder Beginner Contest 345)
    MonoxerProgrammingContest2024(AtCoderBeginnerContest345)\(A\)Leftrightarrow\(100pts\)按照题意模拟即可。点击查看代码intmain(){strings;inta=0,b=0,c=0,i;cin>>s;for(i=0;i<s.size();i++){a+=(s[i]=='<&#......
  • Dwango Programming Contest 6th D 题解
    正好测试一下专栏的题解系统。我省选寄了都怪洛谷/fn/fn/fn/fn/fn/fn/fn题解显然可以对于所有关系建有向边,显然是基环外向树森林。由于是字典序最小,因此找到最小的上一个点没有直接连向边的点一定最优。但是有时取最优会导致最后无法选完,我们考虑无法选完的情况。第一种是......
  • Toyota Programming Contest 2024#3(AtCoder Beginner Contest 344)
    C先预处理出三个数组能拼出的数,存放到map中。查询的时候只需要看这个数是否出现在map里即可。时间复杂度\(O(n^3\logv+Q\logv)\),\(n\leq100\),\(\logv\)是map的时间复杂度。#include<bits/stdc++.h>usingnamespacestd;#defineintlonglongconstintN=3e......
  • Programming Abstractions in C阅读笔记:p312-p326
    《ProgrammingAbstractionsinC》学习第77天,p312-p326,总计15页,第7章完结。一、技术总结第7章主要讲算法分析——引入时间复杂度这一概念来评估算法的快慢。时间复杂度使用大O符号来表示。第7章以排序算法为示例,包含:选择排序,归并排序以及快速排序,这些基本的排序算法都是我们要......
  • AT_abc184_f [ABC184F] Programming Contest 题解
    题目传送门前置知识Meetinthemiddle解法非正解当成超大背包来做,暴力枚举每个数是否进行相加。时间复杂度为\(O(2^{n})\)。llp[50],ans=0;voiddfs(llx,lln,llm,llworth){ if(x==n+1) { if(worth<=m) { ans=max(ans,worth); } } else { if(wo......
  • Microsoft.AspNetCore.Http.Abstractions 2.20 is deprecated
    您想要升级 Microsoft.AspNetCore.Http.Abstractions 包,您需要注意以下几点:Microsoft.AspNetCore.Http.Abstractions 包在 ASP.NETCore2.2 版本后已经被标记为过时,因为它已经被包含在 Microsoft.AspNetCore.App 框架引用中12。因此,您不需要单独引用这个包,只需要在项目......