Hàm trong lập trình c

Được đăng lên bởi Huynh Scarlight
Số trang: 429 trang   |   Lượt xem: 1462 lần   |   Lượt tải: 1 lần
Functional C
Pieter Hartel

Henk Muller

January 3, 1999


Functional C

Pieter Hartel
Henk Muller
University of Southampton University of Bristol

Revision: 6.7


To Marijke


To my family and other sources of inspiration

Revision: 6.7


c 1995,1996 Pieter Hartel & Henk Muller, all rights reserved.

The Computer Science Departments of many universities teach a functional language as the first programming language. Using a functional language with its
high level of abstraction helps to emphasize the principles of programming. Functional programming is only one of the paradigms with which a student should
be acquainted. Imperative, Concurrent, Object-Oriented, and Logic programming
are also important. Depending on the problem to be solved, one of the paradigms
will be chosen as the most natural paradigm for that problem.
This book is the course material to teach a second paradigm: imperative programming, using C as the programming language. The book has been written so
that it builds on the knowledge that the students have acquired during their first
course on functional programming, using SML. The prerequisite of this book is
that the principles of programming are already understood; this book does not
specifically aim to teach ‘problem solving’ or ‘programming’. This book aims to:
Familiarise the reader with imperative programming as another way of implementing programs. The aim is to preserve the programming style, that is,
the programmer thinks functionally while implementing an imperative program.

Provide understanding of the differences between functional and imperative programming. Functional programming is a high level activity. The ordering of
computations and the allocation of storage are automatic. Imperative programming, particularly in C, is a low level activity where the programmer
controls both the ordering of computations and the allocation of storage. This
makes imperative programming more difficult, but it offers the imperative
programmer opportunities for optimisations that are not available to the functional programmer.


Familiarise the reader with the syntax and semantics of ISO-C, especially the
power of the language (at the same time stressing that power can kill). We
visit all dark alleys of C, from void * to pointer arithmetic and assignments
in expressions. On occasions, we use other languages (like C++ and Pascal)
to illustrate concepts of imperative languages that are not present in C. C has...
Functional C
Pieter Hartel Henk Muller
January 3, 1999
Hàm trong lập trình c - Trang 2
Để xem tài liệu đầy đủ. Xin vui lòng
Hàm trong lập trình c - Người đăng: Huynh Scarlight
5 Tài liệu rất hay! Được đăng lên bởi - 1 giờ trước Đúng là cái mình đang tìm. Rất hay và bổ ích. Cảm ơn bạn!
429 Vietnamese
Hàm trong lập trình c 9 10 838