Talks
Summarized using AI

Hacking Cognition

by Jonan Scheffler

In the presentation titled "Hacking Cognition," Jonan Scheffler discusses how software developers can improve their cognitive abilities to enhance their programming skills. The focus is on practical and actionable steps that can lead to a one percent improvement in cognitive performance, which compounds across all coding tasks.

Key points in the presentation include:
- Sleep: Scheffler emphasizes the critical need for adequate sleep (around eight hours) for cognitive recovery and memory reinforcement. Studies show that sleep deprivation can drastically impair cognitive function, even leading high-achieving students to perform at levels comparable to their sleep-deprived peers.
- Exercise: Six minutes of exercise post-learning can significantly enhance cognitive function. It amplifies the primacy effect, whereby individuals remember the beginning of a sequence better. Moderate exercise is recommended over excessive preparation.
- Nutrition: Consumption of low glycemic foods is advised to maintain cognitive function, as spikes in blood sugar can adversely affect brain health, particularly in the dentate gyrus area essential for memory creation.
- Neuroscience Basics: Scheffler touches on the functioning of the brain structures involved in cognition, the importance of neuroplasticity, and how learning occurs across multiple areas in the brain. He shares insights about the thalamus, hippocampus, and olfactory connections to memory.
- Spaced Repetition and Memory Techniques: Strategies like spaced repetition and use of memory techniques such as the Person-Action-Object (PAO) system and memory palaces are discussed as methods to enhance memory retention.
- Experimental Methods: Transcranial direct current stimulation (tDCS) is briefly mentioned as a method to stimulate cognitive performance, though it comes with cautionary advice due to potential risks.

Scheffler concludes by reinforcing the importance of integrating simple, effective changes in daily habits—adequate sleep, exercise, and proper nutrition—to optimize cognitive function and, by extension, programming capabilities. He encourages the audience to recognize and harness their ability to learn and improve.

00:00:20.400 I'm going to talk to you today about hacking cognition—literally how to overclock your brain. More literally than some of you might presume.
00:00:26.560 As Kobe said, my name is Jonan.
00:00:31.840 I tend to linger on that last "n" a little bit because I'm frequently called Jonah, like Jonah and the whale,
00:00:38.320 or Jonas like "My name is Jonas," the Weezer song. Neither of those are accurate; my name is Jonan—think Conan, but with a "J." This image here is courtesy of one Josh Sullivan, a good friend of mine.
00:00:45.039 In talking about cognition, there are a couple of basics I want to cover first. These are pretty simple things that you've all heard before.
00:00:51.280 The goal today is for you to have some actionable steps that will help you improve your clarity of thought and your ability to think. It's not a small thing to set out to do, but I think that as software engineers, it's an important goal.
00:01:02.640 If you can make a one percent improvement in your overall cognitive ability, that's one percent on every bit of code you will ever write again. So, that's certainly worth your time, I think. Sleep, exercise, and nutrition—who has been told to do those things before? Maybe by everyone they’ve ever met, perhaps their mother? Yes, it's true that these things are important, but nobody really has a clear picture of why they matter, especially for our brains.
00:01:19.680 Sleep, obviously, helps us recharge. It helps us remember; while you sleep, you replay the events of your day. Our processes travel through your brain in various ways that we'll go into a little bit later. While you sleep, you literally replay those events as if you were watching them again live, over and over again. That's where your memories come from; they reinforce those chemical and physical changes happening in your brain to build memory and learning.
00:01:45.520 So, Simon says, sleep—you need eight hours. You might think, "But I'm a special snowflake; I can sleep for five hours and still program." You're wrong. You are a special snowflake to me, but when it comes to sleep, you need eight hours. This is particularly important for younger people, and sometimes older individuals can manage with eight hours too. Aim for eight hours of sleep every night.
00:02:03.680 You build up a cumulative sleep deficit when you get less than eight hours. If you get seven hours of sleep for five days in a row, your cognitive ability is significantly impacted. In fact, a study involved a young woman who was at the head of her class—a model student—who participated in a six-week sleep deprivation study. Instead of her normal eight hours, she received seven hours each day for those six weeks, but they allowed her to make up five hours on the weekends. By the end of six weeks, she performed at the level of her non-sleep-deprived peers.
00:02:41.360 So if you think you're able to function at peak capacity on six hours, five hours, or even less, you're entirely wrong. This sleep study that I am referencing involved showing people a game called Simon Says—the little light thing where you push the lights and remember the pattern.
00:03:07.040 They took students who had been sleep-deprived and gave them a series of colored lights to remember. They conducted a double-blind study with two groups: sleep-deprived and non-sleep-deprived. The fascinating part is that the sleep-deprived people performed the task quickly compared to their peers; however, they were wrong about the lights and were convinced they were performing better. This raises an important question: think about that the next time you think you can get by on five hours of sleep and still be a better programmer.
00:03:49.040 Now, exercise. This is a woman named Sabrina Seagal, who got her PhD from UC Irvine, where she conducted a study that demonstrated something simple: just six minutes of exercise can improve your cognitive function. That's all it takes to enhance your ability to learn new things. Exercise basically amplifies the primacy effect; this refers to the tendency of people to remember the beginning of a presentation better than the middle. As we get into the meat of my presentation, you might forget much of what is said.
00:04:48.000 So, remember that just six minutes of exercise after learning something will increase your primacy effect. And here’s an important point: this doesn’t have to be a monumental task. I feel like many developers think, "I'm going to start exercising, so I’ll run five miles a day and work out for three hours!" However, you only need a little bit of exercise every day. If you follow the prescribed 30 minutes a day, three days a week, you'll see improvements. The cognitive ability differences between individuals who exercise moderately and those who work out intensely six days a week are negligible in that regard.
00:05:58.960 So don’t overthink the project of exercise. Instead, consider waking up in the morning and going for a 30-minute walk, and remember to add six minutes of exercise after memorizing something.
00:06:20.480 Finally, let’s discuss nutrition. This is a picture of your dentate gyrus located in the hippocampus. Recent studies indicate that long-term spikes in blood sugar can negatively affect the functioning of the dentate gyrus.
00:06:44.920 This area is one of the few places in the adult brain where neurogenesis occurs. When you’re a child, your brain is more plastic and capable of changes; a notable molecular switch affects this capability. Some MIT researchers recently discovered how to turn this switch back on, but that's a topic for another discussion. The dentate gyrus in the elderly is negatively impacted by long-term sugar spikes. Consuming sweet foods or high-carb foods spikes your blood sugar level, leading to insulin responses that swing up and down.
00:07:51.839 To maintain cognitive function, eat foods that release glucose slowly over time—those that are low in carbohydrates, like proteins and vegetables. Such foods can help maintain low glycemic load. On this screen, you see a chart comparing glycemic index and glycemic load. Lower numbers on both are preferable. Glycemic index alone is misleading; it doesn’t reflect the true nutritional value. Watermelon, for instance, might seem less healthy than wonder bread if you look at glycemic index alone, but as it turns out, watermelon has many fewer carbohydrates.
00:08:51.360 Therefore, aim for protein or vegetable-based foods that offer a sustained glucose release for your brain. These three factors—adequate sleep, regular exercise, and healthy eating—are the best ways you can improve your cognition. You’ll see more gains from those than from the rest of this presentation combined.
00:09:06.960 If you don’t have these fundamentals in line, it may not be worth trying some of my more radical recommendations moving forward.
00:09:31.680 Let's touch on neuroscience—how does it work? Honestly, I'm not a neuroscientist. On the left are researchers, and on the right is me, with a disclaimer that I don't really have a formal background in neuroscience.
00:09:39.760 I’m just a person who sometimes spends my free time reading neuroscience studies on the internet—where everything is true, of course! But the studies I'm referring to are generally well sourced. So while I enjoy learning about this, please take everything I'm about to share with a grain of salt.
00:09:50.400 The first point I want to clarify is that the thalamus, which is the structure at the center of your brain, acts as a router for your senses. When you see, hear, or touch something, that signal gets encoded into electrical signals. Those electrical signals travel through the thalamus and back out to the brain for processing. This vital loop allows you to learn; without it, serious cognitive impairment can occur.
00:10:29.840 Learning occurs throughout this entire loop. It’s not limited to a single spot in the brain. We know that it’s possible to create a memory artificially in a single cell and delete it, as seen in studies with mice. However, cognitive changes happen everywhere in the brain as you learn.
00:10:49.120 Think of it like your computer: data isn’t just stored on the hard drive but also in all sorts of locations. Multiple areas are responsible for your learning. The hippocampus, situated in the limbic system, plays a critical role in short-term to long-term memory conversion, as evidenced by the famous case study of a patient known as H.M.
00:11:31.680 This patient underwent surgery to alleviate epileptic seizures, which involved destroying part of his hippocampus. As a result, he could no longer transfer any information from short-term to long-term memory. He could remember everything before his surgery but would forget new information moments after being introduced to it. His story illustrates the critical role the hippocampus plays in memory.
00:12:09.760 Interestingly, the sense of smell bypasses the thalamus and connects directly to the hippocampus. That’s why olfactory memories are particularly vivid and distinct. This connection explains why you may smell apple pie and suddenly remember standing on your grandmother's porch. If you're studying for an exam, consider incorporating specific scents into your study environment—they may help trigger your memory when recalling the information later.
00:12:50.080 Now, I want to talk about how we learn and the principle of neuroplasticity. Inputs create opportunities for learning throughout your conscious processing centers in the brain. These areas include the dorsal lateral prefrontal cortex, which is responsible for executive functions. Neurogenesis, or the process of generating new neurons, mainly occurs in the hippocampal regions and the limbic system. This was once thought impossible; earlier studies suggested that the brain was a static structure.
00:13:48.320 However, new research—like the persistence of long-term memory study—shows that synaptic growth occurs as a response to learning. Researchers have studied California sea slugs to understand memory. They can be trained to perform tasks—like retracting their gills when shocked—and exhibit memory behaviors lasting up to weeks. By analyzing neurons from the sea slugs, researchers identified that repeated stimulation helped induce synaptic growth.
00:14:40.080 This kind of cellular stimulation shows that learning and memory improve not only through generating new neurons but also by enhancing existing synaptic connections. Spaced repetition, where you space out training or learning sessions, also facilitates improved retention of new information.
00:15:36.720 Thinking back to primacy and recency, we tend to remember the start and end of sequences better than the middle. For example, people generally remember the first few words and the last few words of a list more effectively than the ones in between, a concept known as the primacy effect. Research has shown that exercise can amplify this effect.
00:16:38.720 In studies, participants on a stationary bike for six minutes before memorizing words demonstrated an improved primacy effect. Another factor that enhances memory consolidation is epinephrine, often seen in stress responses. Stress hormones can increase the speed at which recent memories are solidified.
00:17:10.080 However, one limitation is that while recent pieces of information are consolidated rapidly under stress, older memories may not be reinforced as well. It’s crucial to maintain awareness of how experiences shape our memories.
00:18:02.240 Let’s touch briefly on learned helplessness. This condition reflects symptoms akin to chronic depression, arising when individuals feel controlled by negative experiences rather than taking charge of their reality. In studies on learned helplessness, the notion was explored by observing dogs put in situations where they could not control electric shocks.
00:18:58.320 These dogs ultimately accepted their circumstances, even when given the opportunity to escape. This concept resonates with many people today and highlights the importance of recognizing the power one has over their reality.
00:19:46.720 Encouragingly, the brain can also resist such helplessness. Engaging in positive self-talk can create a ripple effect of change; the more you signal positive affirmations, the more your brain learns. It’s a well-known fact that repetition helps in memorization. This is particularly vital for spaced repetition, which optimally occurs just as you’re about to forget what you've learned.
00:20:43.120 An example of this technique can be seen with apps like Anki, which utilize spaced repetition algorithms to aid in learning. They display terms or questions just before you’re likely to forget them, reinforcing your memory.
00:21:37.920 In Joshua Foer's book, "Moonwalking with Einstein," he details memory championship techniques, including a method called the Person-Action-Object (PAO) system. This technique allows individuals to assign vivid imagery and associations to numbers, making them more memorable. For example, someone might visualize Ozzy Osbourne biting the head off Kermit the Frog to represent a particular number combination.
00:22:38.640 This unique association turns an otherwise mundane string of digits into a memorable visual story. Memory palaces serve a similar purpose; they involve placing images along a familiar physical route within a memorable space, allowing one to leverage spatial memory in recall.
00:23:28.400 Let’s shift towards something more experimental: transcranial direct current stimulation (tDCS). This method involves applying a mild electrical current to the brain to stimulate certain regions, enhancing learning capabilities. Though promising, it’s important to approach this technology cautiously as DIY tDCS can be risky.
00:24:28.800 The dorsolateral prefrontal cortex is one of the prime candidates for tDCS applications since it governs executive functions, including attention and memory. Studies show that applying stimulation to this area can lead to noticeable differences in cognitive ability.
00:25:44.640 Experiments using tDCS have shown significant enhancements in memory; however, DIY experiments pose obvious risks, so I don’t recommend them. In fact, I brought a device I designed myself, but I’d caution you against trying this at home.
00:26:40.960 I made a simple device with a couple of battery packs, resistors, and electrodes. While it’s designed to be safe, this sort of experimentation on your own can lead to unpredictable effects. Always prioritize safety over exploration, as interesting as this technology may be. Understand your own limits and the risks involved in experimenting with brain stimulation.
00:27:45.760 So how do we conclude this talk today? I asked you to remember a six-digit number. And many of you did, simply because of the imagery created through Ozzy Osbourne and Kermit the Frog. Not only does this illustrate the effectiveness of visualization, but it highlights how engaging all of your senses and creativity in learning can amplify memory retention.
00:28:48.360 So, my name is Jonan. I’m LeapBot on Twitter, and if you’d like to discuss brain hacking or any other topics, feel free to reach out!
00:29:14.759 Thank you for your time!
Explore all talks recorded at Ruby on Ales 2013
+12