The Programmer’s Brain: What every programmer needs to know about cognition
- Length: 275 pages
- Edition: 1
- Language: English
- Publisher: Manning Publications
- Publication Date: 2021-09-21
- ISBN-10: 1617298670
- ISBN-13: 9781617298677
- Sales Rank: #143975 (See Top 100 Books)
Your brain responds in a predictable way when it encounters new or difficult tasks. This unique book teaches you concrete techniques rooted in cognitive science that will improve the way you learn and think about code.
In The Programmer’s Brain: What every programmer needs to know about cognition you will learn:
- Fast and effective ways to master new programming languages
- Speed reading skills to quickly comprehend new code
- Techniques to unravel the meaning of complex code
- Ways to learn new syntax and keep it memorized
- Writing code that is easy for others to read
- Picking the right names for your variables
- Making your codebase more understandable to newcomers
- Onboarding new developers to your team
Learn how to optimize your brain’s natural cognitive processes to read code more easily, write code faster, and pick up new languages in much less time. This book will help you through the confusion you feel when faced with strange and complex code, and explain a codebase in ways that can make a new team member productive in days!
about the technology
Understanding the cognitive functions that govern the way your brain thinks about coding will help you work smarter, not harder. You’ll improve your productivity, reduce your need for constant rewrites, and say goodbye to spending late nights struggling with new languages.
about the book
The Programmer’s Brain explores the way your brain works when it’s thinking about code. In it, you’ll master practical ways to apply these cognitive principles to your daily programming life. You’ll improve your code comprehension by turning confusion into a learning tool, and pick up awesome techniques for reading code and quickly memorizing syntax. This practical guide includes tips for creating your own flashcards and study resources that can be applied to any new language you want to master. By the time you’re done, you’ll not only be better at teaching yourself—you’ll be an expert at bringing new colleagues and junior programmers up to speed.
The Programmer's Brain brief contents contents foreword preface acknowledgments about this book How this book is organized: A roadmap liveBook discussion forum about the author about the cover illustration Part 1: On reading code better Chapter 1: Decoding your confusion while coding 1.1 Different kinds of confusion in code 1.1.1 Confusion type 1: Lack of knowledge 1.1.2 Confusion type 2: Lack of information 1.1.3 Confusion type 3: Lack of processing power 1.2 Different cognitive processes that affect coding 1.2.1 LTM and programming 1.2.2 STM and programming 1.2.3 Working memory and programming 1.3 Cognitive processes in collaboration 1.3.1 A brief dissection of how the cognitive processes interacted 1.3.2 Cognitive processes regarding programming tasks Chapter 2: Speed reading for code 2.1 Quickly reading code 2.1.1 What just happened in your brain? 2.1.2 Reexamine your reproduction 2.1.3 Reexamining your second attempt at reproducing code 2.1.4 Why is reading unfamiliar code hard? 2.2 Overcoming size limits in your memory 2.2.1 The power of chunking 2.2.2 Expert programmers can remember code better than beginners 2.3 You see more code than you can read 2.3.1 Iconic memory 2.3.2 It’s not what you remember; it’s the way you remember it 2.3.3 Practice chunking Chapter 3: How to learn programming syntax quickly 3.1 Tips for remembering syntax 3.1.1 Disruptions play havoc with your workflow 3.2 How to learn syntax quickly with flashcards 3.2.1 When to use the flashcards 3.2.2 Expanding the set of flashcards 3.2.3 Thinning the set of flashcards 3.3 How to not forget things 3.3.1 Why do we forget memories? 3.3.2 Spaced repetition 3.4 How to remember syntax longer 3.4.1 Two forms of remembering information 3.4.2 Just seeing information is not enough 3.4.3 Remembering information strengthens memories 3.4.4 Strengthen memories by actively thinking Chapter 4: How to read complex code 4.1 Why it’s hard to understand complex code 4.1.1 What’s the difference between working memory and STM? 4.1.2 Types of cognitive load as they relate to programming 4.2 Techniques to reduce cognitive load 4.2.1 Refactoring 4.2.2 Replacing unfamiliar language constructs 4.2.3 Code synonyms are great additions to a flashcard deck 4.3 Memory aids to use when your working memory is overloaded 4.3.1 Creating a dependency graph 4.3.2 Using a state table 4.3.3 Combining dependency graphs and state tables Part 2: On thinking about code Chapter 5: Reaching a deeper understanding of code 5.1 Roles of variables framework 5.1.1 Different variables do different things 5.1.2 Eleven roles to cover almost all variables 5.2 Roles and paradigms 5.2.1 Benefits of roles 5.2.2 Hungarian notation 5.3 Gaining a deeper knowledge of programs 5.3.1 Text knowledge vs. plan knowledge 5.3.2 Different stages of program understanding 5.4 Reading text is similar to reading code 5.4.1 What happens in the brain when we read code? 5.4.2 If you can learn French, you can learn Python 5.5 Text comprehension strategies applied to code 5.5.1 Activating prior knowledge 5.5.2 Monitoring 5.5.3 Determining the importance of different lines of code 5.5.4 Inferring the meaning of variable names 5.5.5 Visualizing 5.5.6 Questioning 5.5.7 Summarizing code Chapter 6: Getting better at solving programming problems 6.1 Using models to think about code 6.1.1 The benefits of using models 6.2 Mental models 6.2.1 Examining mental models in detail 6.2.2 Learning new mental models 6.2.3 How to use mental models efficiently when thinking about code 6.3 Notional machines 6.3.1 What is a notional machine? 6.3.2 Examples of notional machines 6.3.3 Different levels of notional machines 6.4 Notional machines and language 6.4.1 Expanding sets of notional machines 6.4.2 Different notional machines can create conflicting mental models 6.5 Notional machines and schemata 6.5.1 Why schemata matters 6.5.2 Are notional machines semantics? Chapter 7: Misconceptions: Bugs in thinking 7.1 Why learning a second programming language is easier than learning the first one 7.1.1 How to increase the chances of benefiting from existing programming knowledge 7.1.2 Different forms of transfer 7.1.3 Already knowing something: Curse or blessing? 7.1.4 The difficulties of transfer 7.2 Misconceptions: Bugs in thinking 7.2.1 Debugging misconceptions with conceptual change 7.2.2 Suppressing misconceptions 7.2.3 Misconceptions about programming languages 7.2.4 Preventing misconceptions while learning a new programming language 7.2.5 Diagnosing misconceptions in a new codebase Part 3: On writing better code Chapter 8: How to get better at naming things 8.1 Why naming matters 8.1.1 Why naming matters 8.1.2 Different perspectives on naming 8.1.3 Initial naming practices have a lasting impact 8.2 Cognitive aspects of naming 8.2.1 Formatting names supports your STM 8.2.2 Clear names help your LTM 8.2.3 Variable names can contain different types of information to help you understand them 8.2.4 When to evaluate the quality of names 8.3 What types of names are easier to understand? 8.3.1 To abbreviate or not to abbreviate? 8.3.2 Snake case or camel case? 8.4 The influence of names on bugs 8.4.1 Code with bad names has more bugs 8.5 How to choose better names 8.5.1 Name molds 8.5.2 Feitelson’s three-step model for better variable names Chapter 9: Avoiding bad code and cognitive load: Two frameworks 9.1 Why code with code smells creates a lot of cognitive load 9.1.1 A brief intro to code smells 9.1.2 How code smells harm cognition 9.2 The influence of bad names on cognitive load 9.2.1 Linguistic antipatterns 9.2.2 Measuring cognitive load 9.2.3 Linguistic antipatterns and cognitive load 9.2.4 Why linguistic antipatterns cause confusion Chapter 10: Getting better at solving complex problems 10.1 What is problem solving? 10.1.1 Elements of problem solving 10.1.2 State space 10.2 What is the role of the LTM when you solve programming problems? 10.2.1 Is problem solving a cognitive process on its own? 10.2.2 How to teach your LTM to solve problems 10.2.3 Two types of memories that play a role in problem solving 10.3 Automatization: Creating implicit memories 10.3.1 Implicit memories over time 10.3.2 Why automatization will make you program quicker 10.3.3 Improving implicit memories 10.4 Learning from code and its explanation 10.4.1 A new type of cognitive load: Germane load 10.4.2 Using worked examples in your working life Part 4: On collaborating on code Chapter 11: The act of writing code 11.1 Different activities while programming 11.1.1 Searching 11.1.2 Comprehension 11.1.3 Transcription 11.1.4 Incrementation 11.1.5 Exploration 11.1.6 What about debugging? 11.2 Programmer interrupted 11.2.1 Programming tasks require a warm-up 11.2.2 What happens after an interruption? 11.2.3 How to better prepare for interruptions 11.2.4 When to interrupt a programmer 11.2.5 Some thoughts on multitasking Chapter 12: Designing and improving larger systems 12.1 Examining the properties of codebases 12.1.1 Cognitive dimensions 12.1.2 Using CDCB to improve your codebase 12.1.3 Design maneuvers and their trade-offs 12.2 Dimensions and activities 12.2.1 Impact of dimensions on different activities 12.2.2 Optimizing your codebase for expected activities Chapter 13: How to onboard new developers 13.1 Issues in the onboarding process 13.2 Differences between experts and novices 13.2.1 Beginners’ behavior in more depth 13.2.2 Difference between seeing concepts concretely and abstractly 13.3 Activities for a better onboarding process 13.3.1 Limit tasks to one programming activity 13.3.2 Support the memory of the onboardee 13.3.3 Read code together epilogue Some words to close this book index Symbols Numerics A B C D E F G H I J K L M N O P Q R S T U V W
Donate to keep this site alive
How to download source code?
1. Go to: https://www.manning.com
2. Search the book title: The Programmer’s Brain: What every programmer needs to know about cognition
, sometime you may not get the results, please search the main title
3. Click the book title in the search results
3. resources
section, click Source Code
.
1. Disable the AdBlock plugin. Otherwise, you may not get any links.
2. Solve the CAPTCHA.
3. Click download link.
4. Lead to download server to download.