5 Steps to a 5: AP Computer Science A 2024 - Klipp D.B., Johnson D.R., Paymer C.A. 2023


Preface

Way to go! By taking the AP Computer Science A Exam, you’ve decided to gain a deeper knowledge of the world around you. This knowledge will give you an advantage no matter what field you study in the future.

Computer science, ironically, is a much misunderstood subject. Even in this digital age, where people are dependent on their smartphones, they see their phone as a mysterious “black box.” They receive messages and notifications on a daily basis, but, for some reason, they don’t understand that someone had to write the software that makes their life richer. Software developers write the computer programs that people use every day.

The purpose of this book is to help you score a 5 on the AP Computer Science A Exam. Along the way, your Java programming skills and your ability to problem-solve should dramatically improve.

Here are some pieces of advice for you:

Be persistent. Software developers hate it when they can’t figure out how to make a program work and even when they succeed, they always try to think of better ways to solve the problem.

Try to see the big picture. This is good advice not only when studying for this exam, but for life in general. The more you see problems from multiple perspectives, the more likely it is that you will understand how to solve them. Complex program designs require you to step back and view from a distance.

Be patient with yourself and others. Everyone learns at a different rate. Some of the topics in AP Computer Science A are quite challenging, so you may have to reread concepts in this book until you understand them. If you are learning this with other students, help each other out. As a programmer, you should live by the mantra that “we are all in this together.”

Too much of a good thing is a bad thing. Software developers need to strike a balance between structure and creativity. That is, a good developer must understand how to do the technical things (structure) or else their program won’t run. But programmers also need to be creative in order to solve problems in a clever way. Work on improving both of these two skills simultaneously so you can become the best programmer you can be.

Above all else, work toward original thought. You are going to need to learn how to think for yourself in order to become a good programmer. Be curious and learn how things work so that you can apply skills and techniques to new situations. Also, learn how to explain things to other people, as this will develop you as a programmer and leader.

Acknowledgments

I am very grateful that I have been given the opportunity to make revisions to this book so it follows the outline of the ten units in AP Computer Science A Course and Exam Description. First, I’d like to thank Julie Sway, 5 Steps to a 5 AP Computer Science Principles author, for recommending me to her publisher for this project. Second, to Grace Freedson from The Publishing Network and Anya Kozorez from McGraw Hill a huge thank you for giving me this opportunity. And lastly to Poonam Bisht for managing the reorganizing that this book required and understanding my descriptions of the copying/pasting/inserting that was needed.

This revision wouldn’t have been possible without the awesome work done by the original authors Dean Johnson, Carol Paymer, and Aaron Chamberlain. All I did was rearrange their material and add additional material. At first it seemed a simple task, but it morphed into so much more. They did all of the heavy lifting and I hope I that I made them proud.

I would like to thank my husband, Doug, and daughters, Melissa and Samantha, for all of the support they have given me over the years while I travel doing AP work, and to a few of my fellow AP readers and consultants who share this passion and inspire me (Rob Schultz, Sandy Czajka, Kim Hermans, Kelly Schultz, J.P. O'Hara, Judy Hromcik, Ria Galanos, Tim Gallagher, Lester Wainwright, Steve Adriannoff, Cody Henrichsen, Maria Litvin, David Levine, Kathy Larson)—AP CS Rocks!

To my AP Computer Science A students and AP Computer Science A colleagues both past and present, this book is dedicated to you.

Deborah B. Klipp

About the Authors

DEBORAH B. KLIPP began teaching AP Computer Science in 1987 at Mainland Regional High School in Linwood, New Jersey. After teaching math and computer science at Mainland for 25 years, she moved to Florida with her husband and two daughters. She worked at Hillsborough County schools for six years and is currently working at Florida Virtual School. She received a Bachelor of Science in Mathematics, Computer Science minor from Pennsylvania State University and a Master of Arts degree in Education from Rowan University. She has been an AP Computer Science A reader, table leader, and question leader since 1999 and has been an AP College Board Consultant since 2001. She enjoys teaching and sharing her love and passion of AP CSA to teachers during AP Summer Institutes and College Board workshops across the country.

DEAN R. JOHNSON is retired from teaching mathematics and computer science at Fort Atkinson High School, Fort Atkinson, Wisconsin. His students appreciated his passion and enthusiasm for teaching in his own unique style. He has worked as a software developer and project manager for a financial start-up, Blackthorne LLC, in Whitewater, Wisconsin. He is a certified Alice trainer and has contributed exercises for the Learning to Program in Alice, 3rd edition, textbook. He and his wife, Sandy, have four children, David, Jessica, Tommy, and Jordan, who are each amazing in their own way.

CAROL A. PAYMER is retired from teaching computer science at Campolindo High School in Moraga, California. She wrote her first computer program in high school in the early 1970s. She went on to earn an ScB from Brown University and an MS from Stanford before working at Bell Labs, Atari, and various start-ups that have vanished into the ether. Raising her three extraordinary children inspired her to explore teaching and she discovered her calling. She would like to dedicate this book to the many students who fill her days with joy and a sense of purpose and to Richard who runs beside her both uphill and down.