Skip to content

Latest commit

 

History

History
51 lines (33 loc) · 1.3 KB

README.md

File metadata and controls

51 lines (33 loc) · 1.3 KB

algorithms-red-book

Code exercises and personal notes from the book Algorithms (4th edition) by Robert Sedgewick and Kevin Wayne.

⚠️ reading in progress...

Book Resources

My Solutions

Exercise List

Installation of algs4.jar

Follow these instructions "Installing the textbook libraries" to install algs4.jar.

For Mac OS X and .zshrc

Download algs4.jar file to your classes folder like: ~/algs4 (or any other folder of your preference).

Edit ~/.zprofile file:

sudo vim ~/.zprofile

Add the following line and save:

export MY_CLASSPATH=~/algs4
export CLASSPATH=$CLASSPATH:$MY_CLASSPATH/algs4.jar:$MY_CLASSPATH

Do NOT forget to include the imports you need in your code:

# in your code
import edu.princeton.cs.algs4.StdIn;
import edu.princeton.cs.algs4.StdOut;

Compile your java class:

javac BinarySearch.java