Skip to content

A C version library for the textbook Computer Science: An Interdisciplinary Approach written by Robert Sedgewick and Kevin Wayne

License

Notifications You must be signed in to change notification settings

ascendho/Introcs-C

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Overview

This repository hosts the C version source code for the textbook Computer Science: An Interdisciplinary Approach, co-authored by Robert Sedgewick and Kevin Wayne, and is named a Notable Book in the 21st Annual Best of Computing list by the ACM.

The book is intended for a first course in computer science for the next generation of scientists and engineers, pioneering Princeton computer science professors Robert Sedgewick and Kevin Wayne introduces core Java programming techniques in a scientific context, while also demystifying computation and illuminating its intellectual underpinnings.

You can find and download the original Java code and much more other extensive supplementary information, including suggested approaches to programming assignments, checklists, and FAQs, at this companion web site.

Goal

Because the first programming language many computer science students are exposed to is C, it makes sense to translate the java code in the textbook to C. Thus my goal is to make every student or programmer who is currently only familiar with C can follow this book easily.

Strive to keep variable names, function names, program comments, etc. consistent with the original java version, while also writing idiomatic C code.

Index

ELEMENTS OF PROGRAMMING FUNCTIONS OBJECT ORIENTED PROGRAMMING DATA STRUCTURES
HelloWorld.c
UseArgument.c
Ruler.c
IntOps.c
Quadratic.c
LeapYear.c
RandomInt.c
Flip.c
TenHellos.c
PowersOfTwo.c
DivisionPattern.c
HarmonicNumber.c
Sqrt.c
Binary.c
Gambler.c
Factors.c
Sample.c
CouponCollector.c
PrimeSieve.c
SelfAvoidingWalk.c
RandomSeq.c

Contribution

This repo is under construction, so any issue reports and code fixes are welcome. If you want to share your C version code, please fork this repo first and then submit a PR. Note that you should guarantee the correctness of the code in advance and add appropriate comments.

Finally, if you think this repo does work for you, please give a star✨ and actively rise the problem of the code you may experience, I will appreciate your kindness and continue to improve this project.

Copyright

  • The whole C version source code is licensed under MIT.
  • Other materials, including test data, is for self-study only; if you wish to use it for other purposes, please refer to the original author's license and obtain permission to do so.

Development environment

IDE: CLion 2023.1.1

Operating System: Win 11

About

A C version library for the textbook Computer Science: An Interdisciplinary Approach written by Robert Sedgewick and Kevin Wayne

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published