郭志敏的程序员书屋程序员C语言学习

通过这 9 本开源好书学习 C 语言

2017-04-08  本文已影响876人  软体动物Ai

本文由 伯乐在线 - 艾凌风 翻译。未经许可,禁止转载!

英文出处: Steve Emms。欢迎加入翻译组。

Books are very personal things. And programming books are no exception. We all form bonds with programming books that help master the rudiments of a language, and then be able to move on to fully exploit the language’s flexibility.

I have carefully considered the open source C books that are closest to my heart. I have identified 9 books that mean the most to me.

书是非常私人的东西,编程类书籍也不例外。我们都是通过阅读书籍来帮助我们掌握某种语言的基本知识的。随后我们又通过,阅读书籍来探索这门语言的灵活性。我仔细的考察了一些我最喜爱的c语言书籍并从其中选出了对我意义最大的九本。

C is a general-purpose, procedural, portable, high-level programming language that is one of the most popular and influential languages. It was designed to be compiled using a straightforward compiler, to provide low-level access to memory, to provide language constructs that map efficiently to machine instructions, and to require minimal run-time support. Many programming languages owe a considerable debt to C. It has become something of the lingua franca in the programming world.

c语言是一种通用的、面向过程的高级编程语言。也是最具流行度和影响力的编程语言之一。该语言在设计时就被设计为可以通过编译器进行编译,以此来对内存进行底层操作并高效的执行机器指令以及在运行时仅需要最小的支持。很多很多编程语言都得益于c语言。c语言就像是编程界的通用语言一样。

C is fairly simple to understand. It allows the programmer to organize programs in a clear, easy, logical way. It is a very flexible, practical and compact language combined with an easy to read syntax. Code written in C runs quickly, with easy access to the low level facilities in the computer. Compiler directives make it possible to produce a single version of a program compiled for different architectures.

c语言非常易懂。它允许程序员,能够以一种简洁、简单、符合逻辑的方式来组织程序。这是一种非常灵活、实用并且简洁的语言,同时它还具有非常,容易读懂的语法。使用c语言编写的代码运行非常快。可以非常简单的操作计算机的底层设施。通过编译器的指令可以允许我们为不同体系结构的设备生成同一个版本的程序。

C is about freedom. It therefore makes sense to learn C with books that also embody freedom. Take a look at my open source picks and see if any of them grab your fancy. Put the kettle on and enjoy.

c语言是自由的。因此学习c语言的书籍,也是自由的。快来看看我挑选的开源书籍,有没有哪一本能够吸引你?好好享受它吧!

The C Book

《C语言》( The C Book

作者: Mike Banahan, Declan Brady 和 Mark Doran ,350 页

The C Book is designed for programmers who already have some experience of using a modern high-level procedural programming language. The book concentrates on the things that are special to C. In particular, it is the way that C is used which is focused on.

这本书是为那些已经具备使用现代高级面向过程编程语言的程序员设计的。这本书专注于那些c语言的特有之处。尤其是使用c语言的方式是这本书所重点关注的。

Chapters include:

包含以下章节:

The authors give the reader permission to do anything they want with the book provided there is an acknowledgement of the authors and their copyright. From what Mike Banahan has confirmed, the book is effectively under the Creative Commons License.

作者允许读者利用此书做任何他们想做的事情,只需说明作者和版权。经Mike Banahan确认,本书通过知识共享协议发布。

C Elements of Style

风格的要素——C语言版(C Elements of Style

By Steve Oualline (265 pages)

作者 Steve Oualline ,265页

C Elements of Style is a useful guide which covers the principals of good programming style, teaching C and C++ programmers how to write code that can be easily read, understood, and maintained by others. Whether you are a student or professional programmer, you will benefit from the many tips and techniques for constructing elegant, reliable code.

这是一本十分有用的涵编程风格指南,指导c和c++程序员如何去编写可读性良好的,易懂的,易于维护的程序。不论你是一个学生还是专业程序员,你都能从这本书中提供的技巧和技术中获益,构建优雅可靠的代码。

The book attempts to show readers how to build a good programming style into your code. Since computer reads only the code and the human concentrates on the comments, a good programming style pertains to both parts of a program.

这本书意在向读者们展示如何在你的程序中融入风格良好的代码。机器仅处理代码,而人类关注于注释。良好的编程风格与这两部分都有关。

The ultimate goal is to build a well-designed, well-written code which not only make an effective use of the computer and but also contains careful constructed comments to help humans understand it. This condition will ease the debugging, maintenance and enhancement process, which will eventually improve the readability, portability, reliability and maintainability of your code.

我们的最终目标是构建设计良好,编写良好的代码,这种代码对于计算机来说是高效的,同时包含了精心编写的注释用于帮助人类理解程序。这样一来,调试,维护和增强程序,都变得更加容易了。最终还提升了代码的可读性,简洁性,可靠性和可维护性。

Inside, you will find guidelines on writing comments, program heading, determining variable names, statement formatting, statement details, writing preprocessor, organizing directories and creating makefile.

在本书中,你可以找到有关编写注释,程序头,变量命名,语句格式化,语句细节,编写预处理器命令,组织目录和创建makefile的指南。

This book is published under the Creative Commons License.

本书通过知识共享协议发布。

Build Your Own Lisp

《编写你自己的Lisp语言》(Build Your Own Lisp

By Daniel Holden (212 pages)

作者 Daniel Holden ,212页

Learn the C programming language and at the same time learn how to build your very own programming language, a minimal Lisp, in under 1000 lines of code.

在学习C语言的同时学习如何创造你自己的编程语言——一个最简的Lisp语言(仅用不到1000行代码)。

This book is for anyone wanting to learn C, or who has once wondered how to build their own programming language. It is not designed as a first programming language book, as you need some programming experience to make your way through the content.

这本书是为两种人写的,一种是想要学习c语言的人,另一种是想要知道如何创建一门语言的人。本书并不适合作为第一本入门书籍,因为你需要一些编程经验才能读懂它的内容。

Build Your Own Lisp is licensed under Creative Commons Attribution-NonCommercial-ShareAlike 3.0.

本书基于Creative Commons Attribution-NonCommercial-ShareAlike 3.0.协议发布

A paperback is available to purchase from Amazon.

纸质版可以在Amazon上购买。

The GNU C Reference Manual

《 GNU C语言参考手册》(The GNU C Reference Manual

By Trevis Rothwell, James Youngman (91 pages)

作者 Trevis Rothwell, James Youngman ,91页

The GNU C Reference Manual is a reference for the C programming language and aims to document the 1989 ANSI C standard, the 1999 ISO C standard, and the current state of GNU extensions to standard C. It is not designed for new programmers.

本书是一本C语言参考手册,意在写明C89,C99标准以及当前GNU对标准c语言的扩展情况。本书并不适合新手阅读。

Chapters cover:

包含以下章节:

The book is available under the terms of the GNU Free Documentation License, Version 1.3 or later.

本书基于GNU Free Documentation License Version 1.3 及其更新版本发布。

The GNU C Programming Tutorial

《GNU C 语言编程教程》(The GNU C Programming Tutorial

By Mark Burgess, Ron Hale-Evans (290 pages)

作者 Mark Burgess, Ron Hale-Evans ,290页

The GNU C Programming Tutorial introduces the reader to the basic ideas in a logical order. It offers detailed coverage of each of the main elements of the C language and how to program in C, with special emphasis on the GNU/Linux compiler and associated software.

本书以逻辑顺序向读者介绍了 C 语言的基本内容。本书内容涵盖了 C 语言的全部主要内容的细节以及如何使用 C 语言编程,特别强调了GNU/Linux编译器以及相关软件。

There are chapters devoted to functions, variables and declarations, scope, expressions and operators, parameters, pointers, decisions, loops, arrays, strings, input and output, and much more.

一些章节主要介绍了函数,变量以及声明,作用域,表达式和操作符,参数,指针,判定,循环,数组,字符串,输入输出等等。

The GNU C Programming Tutorial is released under the GNU Free Documentation License, Version 1.1.

本书基于GNU Free Documentation 协议 Version 1.1版发布。

Essential C

《C语言基础》(Essential C

By Nick Parlante (45 pages)

作者 Nick Parlante ,45页

This Stanford CS Education is a fairly brief document which explains all the common features and techniques for C. The coverage is pretty quick, so it is targeted at a programmer with a background in another language.

这份简短的文档解释了 C 语言全部的常用特性和技术。这份文档十分简洁,因此它的目标人群是已经具有其他编程语言背景的人。

Topics include variables, int types, floating point types, promotion, truncation, operators, control structures (if, while, for), functions, value parameters, reference parameters, structs, pointers, arrays, the pre-processor, and the standard C library functions.

内容包括变量,整型,浮点型,类型提升,截断,操作符,控制结构(if,while,for),函数,数值参数,引用参数,结构体,指针,数组,预处理器以及 C 语言标准库函数。

Table of Contents:

Introduction

Basic Types and Operators

Control Structures

Complex Data Types

Functions

Odds and Ends

Advanced Arrays and Pointers

Operators and Standard Library Reference

目录:

The author’s description indicates this book is issued under an open-source like license.

根据作者的描述,我们得知这是一本基于开源协议发布的书籍。

Beej’s Guide to C Programming

《Beej的C语言教程》(Beej’s Guide to C Programming

By Brian “Beej” Hall (130 pages)

作者 Brian “Beej” Hall ,130 pages

Beej’s Guide to C Programming tries to lead the reader from complete and utter sheer lost confusion on to the sort of enlightened bliss that can only be obtained though pure C programming.

本书试图为那些心存困惑的读者带来一种仅能通过纯粹c语言编程而产生的快感。

Chapters:

章节:

一个c语言表达式可以包含其他的表达式以及运算符。文章还介绍了ifwhiledo while以及程序重复执行的for语句。

This book is licensed under the Creative Commons Attribution-Noncommercial- No Derivative Works 3.0 License.

本书基于Creative Commons Attribution-Noncommercial- No Derivative Works 3.0 协议发布。

Modern C

《现代C语言》(Modern C

By Jens Gustedt (310 pages)

作者 Jens Gustedt ,310页

Modern C seeks to motivate the reader to climb to higher levels of knowledge. The book is divided into five levels:

本书鼓励读者逐级探索c语言的特性。内容一共分为如下五个层级:

This book is licensed under the Creative Commons Attribution-Noncommercial- No Derivative Works 3.0 License.

本书基于Creative Commons Attribution-Noncommercial- No Derivative Works 3.0 协议发布

An Introduction to GCC

《GCC简介》(An Introduction to GCC

By Brian Gough (144 pages)

作者 Brian Gough ,144页

An Introduction to GCC provides an introduction to the GNU C and C++ Compilers, gcc and g++, which are part of the GNU Compiler Collection (GCC).

本书介绍了 GNU C 语言和 C++编译器——gcc 和 g++,它们是 GNU 编译器套装(GCC)的一部分。

This book explains how to use the compiler itself. Based on years of observation of questions posted on mailing lists, it guides the reader straight to the important options of GCC.

本书介绍了如何使用编译器。通过多年以来对邮件列表中的问题的观察,本书带领读者直击 GCC 的重要选项。

Chapters:

章节介绍:

This book is published under the GNU Free Documentation License

本书基于GNU Free Documentation协议发布


Here are some informative C Books to download without charge, but which regrettably are not released under an open source license, or where license information is unclear. In no particular order:

很多c语言书籍都可以免费下载,但是可惜的是它们并没有以开源协议来发布,或其基于何种协议并没有明确说明。以下对其进行介绍,排名不分先后:

And finally, my recommendation if you want to buy a canonical reference book is this title: The C Programming Language. Terse, not for beginners, but widely regarded as the classic C programming book.

最后,如果你想买一本权威参考书,请认准《C程序设计语言》(The C Programming Language)。这本书非常简练,不适合新手,但是被广泛认为是一部经典。

上一篇下一篇

猜你喜欢

热点阅读