Data and algorithms are rapidly transforming law enforcement and the criminal legal system, including how police officers are deployed, how discrimination is detected, and how sentencing, probation, and parole terms are set. Modern computational and statistical methods offer the promise of greater efficiency, equity, and transparency, but their use also raises complex legal, social, and ethical questions. In this course, we examine the often subtle relationship between law, public policy, and technology, drawing on recent court decisions, and applying methods from machine learning and game theory. We survey the legal and ethical principles for assessing the equity of algorithms, describe computational techniques for designing fairer systems, and consider how anti-discrimination law and the design of algorithms may need to evolve to account for machine bias. Concepts will be developed in part through guided in-class coding exercises, though prior programming experience is not necessary.