textbookProgrammingAbstractionsinC(Addison-Wesley,1998).In2002-03,Julie ZelenskiupdateditforusewiththeC++programminglanguage,whichwebeganusing inCS106BandCS106Xduringthatyear.Althoughtherevisedtextworkedfairlywellat theoutset,CS106BandCS106Xhaveevolvedinrecentyearssothattheirstructureno ...
(1)quadratic time(二次时间) p293, Algorithms like selection sort that exhibit O(N^2) performance are said to run in quadratic time。 2.线性查找(linear search) p293, Because the for loop in the implementation executes n time, you expect the performance of LinearSearch——as its name impli...
《Programming Abstractions in C》学习第80天,p338-p346,总计9页。 一、技术总结 栈的实现包括入栈、出栈、判断栈是否为满,判断栈是否为空等。作者结合RPN计算器来实现,稍显无聊。 /* * File: rpncalc.c * --- * This program simulates an electronic calculator that uses * reverse Polish notation...
一、技术总结 1.字符串数组 学习《Programming Abstractions in C》第75页的时候,遇到一段代码: 这里直接使用string,不理解其中的用法,想着查缺补漏,便去找来《The C Programming Language》复习,在第5章“Pointers and Arrays”找到相关内容,便开始阅读起来,读完之后再回来看,发现代码后续的内容就是“Multidimensional...
《Programming Abstractions In C》阅读P72-p75,每次阅读其实都有很多内容需要总结,这里摘抄其中一部分。一、技术总结1.字符串数组学习《Programming Abstractions in C》第75页的时候,遇到一段代码: static string bigCities[] = { "New York", "Los Angeles", "Chicago", "Houston", "Philadelphia", "San ...
《Programming Abstractions in C》学习第76天,p308-p311总结,总计4页。 一、技术总结 1.快速排序伪代码 #include <stdbool.h> static int Partition(int array[], int n); /* * Implementation notes: SortIntegerArray * --- * This implementation of SortIntegerArray uses the Quicksort * ...
Programming Abstractions in C阅读笔记:p202-p234 《Programming Abstractions in C》学习第65天,p202-p234总结。 一、技术总结 完成第五章学习,第五章介绍递归在实际问题中的进一步应用,例如汉诺塔问题,数学中的排列问题,更有难度。使用递归解决问题时有时候需要借助wrapper function。
Programming Abstractions in C阅读笔记:p338-p346 《Programming Abstractions in C》学习第80天,p338-p346,总计9页。 一、技术总结 栈的实现包括入栈、出栈、判断栈是否为满,判断栈是否为空等。作者结合RPN计算器来实现,稍显无聊。 /* * File: rpncalc.c...
《Programming Abstractions In C》学习第57天,开始第4章“Introduction to Recursion”的学习,p161-p165,总结如下。 一、技术总结 1.recursion vs stepwise refinement 答:p164, The strategy, called recursion is defined as any solution technique in which large problems are solved by reducing them to smalle...
vi. to stick firmely(附着,遵循)。后面常接介词to。 三、参考资料 1. 编程 (1)Eric S.Roberts,《Programming Abstractions in C》 2. 英语 (1)Etymology Dictionary: https://www.etymonline.com (2) Cambridage Dictionary: https://dictionary.cambridge.org 欢迎搜索及关注:编程人(a_codists)...