Don't Teach Coding. Lindsey D. Handley
R. FOSTER
LINDSEY D. HANDLEY
This edition first published 2020 © 2020 by John Wiley & Sons, Inc. All rights reserved.
All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted, in any form or by any means, electronic, mechanical, photocopying, recording or otherwise, except as permitted by law. Advice on how to obtain permission to reuse material from this title is available at http://www.wiley.com/go/permissions.
The right of Lindsey Handley and Stephen Foster to be identified as the authors of this work has been asserted in accordance with law.
Registered Office(s) John Wiley & Sons, Inc., 111 River Street, Hoboken, NJ 07030, USA
Editorial Office John Wiley & Sons, Inc., River Street, Hoboken, NJ 07030, USA
For details of our global editorial offices, customer services, and more information about Wiley products visit us at www.wiley.com.
Wiley also publishes its books in a variety of electronic formats and by print-on-demand. Some content that appears in standard print versions of this book may not be available in other formats.
Limit of Liability/Disclaimer of Warranty While the publisher and authors have used their best efforts in preparing this work, they make no representations or warranties with respect to the accuracy or completeness of the contents of this work and specifically disclaim all warranties, including without limitation any implied warranties of merchantability or fitness for a particular purpose. No warranty may be created or extended by sales representatives, written sales materials or promotional statements for this work. The fact that an organization, website, or product is referred to in this work as a citation and/or potential source of further information does not mean that the publisher and authors endorse the information or services the organization, website, or product may provide or recommendations it may make. This work is sold with the understanding that the publisher is not engaged in rendering professional services. The advice and strategies contained herein may not be suitable for your situation. You should consult with a specialist where appropriate. Further, readers should be aware that websites listed in this work may have changed or disappeared between when this work was written and when it is read. Neither the publisher nor authors shall be liable for any loss of profit or any other commercial damages, including but not limited to special, incidental, consequential, or other damages.
Library of Congress Cataloging-in-Publication Data
Names: Handley, Lindsey, author. | Foster, Stephen, 1985- author.
Title: Don't teach coding : until you read this book / Lindsey D. Handley, Stephen R. Foster.
Description: First edition. | Hoboken, NJ : Jossey-Bass/John Wiley & Sons, 2020. | Includes bibliographical references and index.
Identifiers: LCCN 2019055396 (print) | LCCN 2019055397 (ebook) | ISBN 9781119602620 (paperback) | ISBN 9781119602644 (adobe pdf) | ISBN 9781119602637 (epub)
Subjects: LCSH: Computer programming—Study and teaching.
Classification: LCC QA76.27 .H364 2020 (print) | LCC QA76.27 (ebook) | DDC 005.13—dc23
LC record available at https://lccn.loc.gov/2019055396 LC ebook record available at https://lccn.loc.gov/2019055397
Cover Design: Wiley
To our students, you taught us to teach.
To our teachers, you taught us to learn.
About the Authors
Dr. Stephen R. Foster is a researcher, author, and co-founder of multiple social enterprises with a mission to teach teachers how to teach coding. A fierce advocate for the power of coding to bring about worldwide change, he has himself coded to generate peer-reviewed scientific results, coded to build educational technology solutions for teachers and students, and coded to bootstrap educational startups and non-profit organizations out of thin air. All in all, these countless lines of code have all been in service of a single vision: to establish coding education as a basic human right across the globe. In short, he codes to teach coding.
Dr. Lindsey D. Handley is a researcher, entrepreneur, teacher, and author. For the last 10 years, the National Science Foundation has funded the research, design work, and the social enterprises that she operates. As a skilled coder, data scientist, and biochemist, she envisions a world in which we no longer suffer from a worldwide shortage of scientific fluency. To this end, she fights for the unification of science and education on two fronts: the use of science to improve education; and the improved teaching of science worldwide. In short, she applies science to design better ways of teaching science.
Together, they are the co-founders and leaders of ThoughtSTEM and MetaCoders.org – two social enterprises that have touched the lives of hundreds of thousands of beginning coders worldwide.
Acknowledgments
Thank you to the following people for taking time to read and provide feedback on earlier drafts: Dr. Jody Kelly, Dr. Shriram Krishnamurthi, Dr. Janet Siegmund, Kelly Foster, Matthew Butterick, and Allan Schougaard. Your contributions helped make this book what it is.
Thank you to the creators of Racket for their trailblazing work in language-oriented programming, without which we wouldn't have been able to design the programming languages for this book about programming languages.
Introduction
If there's one thing this book seeks to address, it is: What are programming languages?
It sounds simple, but answering this question deeply will require us to ask other questions: Why do we call them “languages”? Why are there so many? Why do people fluent in them get paid so much? How are they related to those other things we call “languages” (like English, Spanish, or American Sign Language)? Where do they come from? Where are they going? How do we learn them? What happens in your brain when you do?
And, above all:
How do we teach them?
Japan, Italy, England, and Finland are just a few of the countries that have begun to mandate coding education throughout K-12 public education. Computer science educational standards now exist in 22 U.S. states – two of which have passed legislation that requires coding education statewide from elementary to high school.
As the world embarks on a global change to its collective education systems, it is worth asking some basic questions.
Technically, this book is about what you should know before you start teaching (or learning) a programming language. But the book will also teach you a few simple languages in order to make headway on some of the deeper questions.
There is a structure that frames the four chapters in this book, each of which have five parts – five arcs that recur from chapter to chapter.
The Wizard's Tale is the only fictional arc of the book. At the beginning of each chapter, this narrative introduces the main ideas in a lighthearted way. Sometimes the truest things can only be said in fiction.
The pair of arcs called A Language Without and A Language Within are where you'll learn about coding – one language at a time. In A Language Without, we'll examine how the design of a language gives its users