from the world's big
Good Programming Is Like Good Writing
David Heinemeier Hansson is a Danish programmer and the creator of the Ruby on Rails open source web development framework. He is also a partner with Jason Fried at the web-based software development firm 37signals. In 2005 he was given with the Hacker of the Year by Google and O'Reilly award for his creation of Ruby on Rails. He and Fried have also co-authored the New York Times bestseller "Rework," which reveals their secrets for boosting business productivity in the Internet age.
Question: What makes Ruby a special language?
David Heinemeier Hansson: To me good programming is just like good writing. It's succinct. You're expressing what you want to say in as few words as possible. You're picking just the right words for the sentence, and it's sort of a grand thing. A program is just like an article or a book; it's composed of tiny things like words that form into sentences, and paragraphs, and chapters, and so forth. A programming language—a good programming language—allows you to build a program in just the same way.
So you'll have methods that are really short. A big part of what makes Ruby so special to work with is just how much expression you can pack into few lines of code. When I compare it to something like Java where it takes perhaps ten lines to express a very simple operation, that same operation can be expressed in a single line of Ruby. And that just makes understanding the entire program that much easier when the density of expression is so much higher, and it's not just because it's short. There's plenty of programming languages where you can write exceptionally short code, and it's completely unreadable afterward. Ruby has this uncanny ability to just be shortened the same way your thought would be short, but no shorter than that.
The other part of it is also having a grand or free mode of expression that there are many different ways that you can say something. So for example: Lots of programming languages have—or all program languages have—conditionals. If something is true, do this. Now, sometimes you want the positive version of that. Like, “If employee works here, then print this screen.” Sometimes you want the opposite. In most program languages, you would go about that by saying, “If not programmer works here, then do this.” That's not a very natural way of expressing that. You would never say that in real life.
In Ruby, you can say, “Unless the programmer works here, do this.” So it's just all those little things where the creator of Ruby thought about the whole picture. It's not just that you can get something done. All programming languages can do the same things. There's nothing you can do in Ruby that you couldn't do in some other programming language. What makes Ruby special is how you say it.
Compared to natural languages, I think there's also just something to the tone and they rhythm of it. I'm Danish. I speak Danish, and I admit that Danish is not a very pretty language. Thankfully, it's not as ugly as German, which I think is probably one of the ugliest languages of all time. But if you compare something like German to something like French, you don't have to speak either language to hear that French is obviously the prettier language.
I think if somebody who doesn't even know code, they can look at a piece of Ruby code, and they can appreciate that Ruby is French and Java is German. That's sort of really the appeal to it. Because you have to work with this stuff all the time. Programmers often work for many, many, many hours a day, and this is your main mode of expression. It has to be good. If it's not good, if you're speaking in an ugly language every day for eight or ten hours a day... well, I won't say that it turns you into an ugly person, but I like to just surround myself with beautiful things. Ruby is beautiful; lots of other programming languages are much less so.
Question: Do programmers need to like the languages in which they code?
David Heinemeier Hansson: I think in the past, programming languages and environments have been determined by everything but the beauty of expression. It's been determined by “We have to make this really fast. We have to make this really efficient. We have to make this really logical. There has to be only one way of doing things.” All of these other concerns that you would think about when you would think about somebody approaching it in a very sort of binary approach. That's sort of the best way I can express it.
Ruby comes from a much different angle. In fact, the creator of Ruby said that his main goal of creating Ruby was to make programmers happy. Now, you're introducing something that in many ways seems like a foreign concept. You're talking about code. What does happiness have to do with anything? How does happiness play into this stuff? It absolutely does because programmers—surprisingly enough, I'm sure to a lot of people—are humans, too. And humans just respond to emotional things. They respond to beauty, they respond to a general sense of well being and liking your tools. It's not enough that your tools can get the job done. It's how they get them done. It's whether you like wielding those tools day out and day in.
And I've talked to a lot of Ruby programmers who came to sort of the edge of their career thinking they've been working in Java, or C-Sharp, or some other language that was just driving them miserable. And they were thinking, “You know what? I know how to do this stuff, but it's probably not for me. I'm not happy working with these languages or environments every day. I'm going to quit.” And then some of them found Ruby. And it almost sounds cheesy as sort of a religious experience that they find this program language that all of a sudden makes it interesting for them again to be programmers. But it's absolutely true. I felt exactly the same way. I was absolutely not convinced that I was going to be a programmer when I was working with PHP and Java.
To me, at that point programming was just something I had to do to get programs. It was sort of just a functional thing I unfortunately had to go through in order to realize the ideas that I had for programs. For me, Ruby just changed that such that the act itself was pleasurable. And I think that's just a magic moment. When you change over from not just being able to do the job to actually enjoying the job. That's just a huge difference. And I think that the product in the end also reflects that. The programs I write now are much better than the programs I wrote when I didn't like my tools.
Recorded on July 22, 2010
Interviewed by Peter Hopkins
"A big part of what makes Ruby so special to work with is just how much expression you can pack into a few lines of code," says Hansson.
Innovation in manufacturing has crawled since the 1950s. That's about to speed up.
So far, 30 student teams have entered the Indy Autonomous Challenge, scheduled for October 2021.
- The Indy Autonomous Challenge will task student teams with developing self-driving software for race cars.
- The competition requires cars to complete 20 laps within 25 minutes, meaning cars would need to average about 110 mph.
- The organizers say they hope to advance the field of driverless cars and "inspire the next generation of STEM talent."
Indy Autonomous Challenge<p>Completing the race in 25 minutes means the cars will need to average about 110 miles per hour. So, while the race may end up being a bit slower than a typical Indy 500 competition, in which winners average speeds of over 160 mph, it's still set to be the fastest autonomous race featuring full-size cars.</p><p style="margin-left: 20px;">"There is no human redundancy there," Matt Peak, managing director for Energy Systems Network, a nonprofit that develops technology for the automation and energy sectors, told the <a href="https://www.post-gazette.com/business/tech-news/2020/06/01/Indy-Autonomous-Challenge-Indy-500-Indianapolis-Motor-Speedway-Ansys-Aptiv-self-driving-cars/stories/202005280137" target="_blank">Pittsburgh Post-Gazette</a>. "Either your car makes this happen or smash into the wall you go."</p>
Illustration of the Indy Autonomous Challenge
Indy Autonomous Challenge<p>The Indy Autonomous Challenge <a href="https://www.indyautonomouschallenge.com/rules" target="_blank">describes</a> itself as a "past-the-post" competition, which "refers to a binary, objective, measurable performance rather than a subjective evaluation, judgement, or recognition."</p><p>This competition design was inspired by the 2004 DARPA Grand Challenge, which tasked teams with developing driverless cars and sending them along a 150-mile route in Southern California for a chance to win $1 million. But that prize went unclaimed, because within a few hours after starting, all the vehicles had suffered some kind of critical failure.</p>
Indianapolis Motor Speedway
Indy Autonomous Challenge<p>One factor that could prevent a similar outcome in the upcoming race is the ability to test-run cars on a virtual racetrack. The simulation software company Ansys Inc. has already developed a model of the Indianapolis Motor Speedway on which teams will test their algorithms as part of a series of qualifying rounds.</p><p style="margin-left: 20px;">"We can create, with physics, multiple real-life scenarios that are reflective of the real world," Ansys President Ajei Gopal told <a href="https://www.wsj.com/articles/autonomous-vehicles-to-race-at-indianapolis-motor-speedway-11595237401?mod=e2tw" target="_blank">The Wall Street Journal</a>. "We can use that to train the AI, so it starts to come up to speed."</p><p>Still, the race could reveal that self-driving cars aren't quite ready to race at speeds of over 110 mph. After all, regular self-driving cars already face enough logistical and technical roadblocks, including <a href="https://www.bbc.com/news/technology-53349313#:~:text=Tesla%20will%20be%20able%20to,no%20driver%20input%2C%20he%20said." target="_blank">crumbling infrastructure, communication issues</a> and the <a href="https://bigthink.com/paul-ratner/would-you-ride-in-a-car-thats-programmed-to-kill-you" target="_self">fateful moral decisions driverless cars will have to make in split seconds</a>.</p>But the Indy Autonomous Challenge <a href="https://static1.squarespace.com/static/5da73021d0636f4ec706fa0a/t/5dc0680c41954d4ef41ec2b2/1572890638793/Indy+Autonomous+Challenge+Ruleset+-+v5NOV2019+%282%29.pdf" target="_blank">says</a> its main goal is to advance the industry, by challenging "students around the world to imagine, invent, and prove a new generation of automated vehicle (AV) software and inspire the next generation of STEM talent."
A new Harvard study finds that the language you use affects patient outcome.
- A study at Harvard's McLean Hospital claims that using the language of chemical imbalances worsens patient outcomes.
- Though psychiatry has largely abandoned DSM categories, professor Joseph E Davis writes that the field continues to strive for a "brain-based diagnostic system."
- Chemical explanations of mental health appear to benefit pharmaceutical companies far more than patients.
Challenging the Chemical Imbalance Theory of Mental Disorders: Robert Whitaker, Journalist<span style="display:block;position:relative;padding-top:56.25%;" class="rm-shortcode" data-rm-shortcode-id="41699c8c2cb2aee9271a36646e0bee7d"><iframe type="lazy-iframe" data-runner-src="https://www.youtube.com/embed/-8BDC7i8Yyw?rel=0" width="100%" height="auto" frameborder="0" scrolling="no" style="position:absolute;top:0;left:0;width:100%;height:100%;"></iframe></span><p>This is a far cry from Howard Rusk's 1947 NY Times editorial calling for mental healt</p><p>h disorders to be treated similarly to physical disease (such as diabetes and cancer). This mindset—not attributable to Rusk alone; he was merely relaying the psychiatric currency of the time—has dominated the field for decades: mental anguish is a genetic and/or chemical-deficiency disorder that must be treated pharmacologically.</p><p>Even as psychiatry untethered from DSM categories, the field still used chemistry to validate its existence. Psychotherapy, arguably the most efficient means for managing much of our anxiety and depression, is time- and labor-intensive. Counseling requires an empathetic and wizened ear to guide the patient to do the work. Ingesting a pill to do that work for you is more seductive, and easier. As Davis writes, even though the industry abandoned the DSM, it continues to strive for a "brain-based diagnostic system." </p><p>That language has infiltrated public consciousness. The team at McLean surveyed 279 patients seeking acute treatment for depression. As they note, the causes of psychological distress have constantly shifted over the millennia: humoral imbalance in the ancient world; spiritual possession in medieval times; early childhood experiences around the time of Freud; maladaptive thought patterns dominant in the latter half of last century. While the team found that psychosocial explanations remain popular, biogenetic explanations (such as the chemical imbalance theory) are becoming more prominent. </p><p>Interestingly, the 80 people Davis interviewed for his book predominantly relied on biogenetic explanations. Instead of doctors diagnosing patients, as you might expect, they increasingly serve to confirm what patients come in suspecting. Patients arrive at medical offices confident in their self-diagnoses. They believe a pill is the best course of treatment, largely because they saw an advertisement or listened to a friend. Doctors too often oblige without further curiosity as to the reasons for their distress. </p>
Image: Illustration Forest / Shutterstock<p>While medicalizing mental health softens the stigma of depression—if a disorder is inheritable, it was never really your fault—it also disempowers the patient. The team at McLean writes,</p><p style="margin-left: 20px;">"More recent studies indicate that participants who are told that their depression is caused by a chemical imbalance or genetic abnormality expect to have depression for a longer period, report more depressive symptoms, and feel they have less control over their negative emotions."</p><p>Davis points out the language used by direct-to-consumer advertising prevalent in America. Doctors, media, and advertising agencies converge around common messages, such as everyday blues is a "real medical condition," everyone is susceptible to clinical depression, and drugs correct underlying somatic conditions that you never consciously control. He continues,</p><p style="margin-left: 20px;">"Your inner life and evaluative stance are of marginal, if any, relevance; counseling or psychotherapy aimed at self-insight would serve little purpose." </p><p>The McLean team discovered a similar phenomenon: patients expect little from psychotherapy and a lot from pills. When depression is treated as the result of an internal and immutable essence instead of environmental conditions, behavioral changes are not expected to make much difference. Chemistry rules the popular imagination.</p>
Why Depression Isn't Just a Chemical Imbalance<span style="display:block;position:relative;padding-top:56.25%;" class="rm-shortcode" data-rm-shortcode-id="fbc027c9358dad4a6d9e2704fc9ddb04"><iframe type="lazy-iframe" data-runner-src="https://www.youtube.com/embed/GAC9ODvSxh0?rel=0" width="100%" height="auto" frameborder="0" scrolling="no" style="position:absolute;top:0;left:0;width:100%;height:100%;"></iframe></span><p>Many years ago, my best friend tried to quit smoking. He asked for help. While I'm no addiction expert, I offered what I knew from my fitness toolkit: breathing exercises and cardiovascular training, methods for strengthening his body and mind that could, I hoped, inspire him to take better care of himself in general. He replied, "No, I meant something like a pill."</p><p>A few years later, he quit for good. After failing the cold turkey method a number of times, it finally stuck. Maybe it was watching his children grow up—the reason my parents quit when I was young. This method is not easy, however. It challenges you; it forces you to confront your demons; it drastically affects your brain chemistry. Yet, in the long run, it sometimes works. </p><p>Sometimes pills work, too. But often they do not. The journalist Robert Whitaker, author of "Anatomy of an Epidemic," discussed the clinical trial process <a href="https://bigthink.com/mind-brain/antidepressants-dangers" target="_self">during our recent conversation</a>. While the FDA process appears thorough from the outside, pharmaceutical companies only need to prove that a drug works better than placebo, not that it works for the most amount of people. He continues, </p><p style="margin-left: 20px;">"Let's say you have a drug that provides a relief of symptoms in 20 percent of people. In placebo, it's 10 percent. How many people in that study do not benefit from the drug? Nine out of 10. How many people are exposed to the adverse effects of the drug? 100 percent."</p><p>Even though some pharmacological interventions show little efficacy, and even though Xanax, an addictive and destructive benzodiazepine that only showed <a href="https://www.ncbi.nlm.nih.gov/pmc/articles/PMC5846112/" target="_blank">short-term (four weeks) efficacy</a> in clinical trials, is being prescribed for many months and years, doctors continue to use the language of clinical neuroscience to describe mental health issues. If chemistry is the problem, people will turn to chemistry for the solution. </p><p>Perhaps we should, as psychiatrist Dean Schuyler <a href="https://bigthink.com/surprising-science/antidepressant-effects" target="_self">writes</a> in a 1974 book, recognize that most depressive episodes "will run their course and terminate with virtually complete recovery without specific intervention." The problem is that idea isn't profitable. As long as the gatekeepers continue to use the language of chemical imbalances to describe what for many is just an episodic case of the "blahs," we'll continue creating more problems than we solve.</p><p>--</p><p><em>Stay in touch with Derek on <a href="http://www.twitter.com/derekberes" target="_blank">Twitter</a>, <a href="https://www.facebook.com/DerekBeresdotcom" target="_blank">Facebook</a> and <a href="https://derekberes.substack.com/" target="_blank">Substack</a>. His next book is</em> "<em>Hero's Dose: The Case For Psychedelics in Ritual and Therapy."</em></p>
Here's why you might eat greenhouse gases in the future.
- The company's protein powder, "Solein," is similar in form and taste to wheat flour.
- Based on a concept developed by NASA, the product has wide potential as a carbon-neutral source of protein.
- The man-made "meat" industry just got even more interesting.
Seriously sustainable<img type="lazy-image" data-runner-src="https://assets.rebelmouse.io/eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpbWFnZSI6Imh0dHBzOi8vYXNzZXRzLnJibC5tcy8xOTk0MDIzNS9vcmlnaW4ucG5nIiwiZXhwaXJlc19hdCI6MTYyMjM4NTMzMX0.BCEfYnn6C3z1zUHIS38xOWjXktgamNBi5iyqklSMYK8/img.png?width=980" id="ea524" class="rm-shortcode" data-rm-shortcode-id="50533380eeb18eb5833b6b6aa3abec38" data-rm-shortcode-name="rebelmouse-image" />
Image source: Solar Foods<p>Solar Foods makes Solein by extracting CO₂ from air using <a href="https://www.fastcompany.com/90356326/we-have-the-tech-to-suck-co2-from-the-air-but-can-it-suck-enough-to-make-a-difference" target="_blank">carbon-capture technology</a>, and then combines it with water, nutrients and vitamins, using 100 percent renewable solar energy from partner <a href="https://www.fortum.com" target="_blank">Fortum</a> to promote a natural fermentation process similar to the one that produces yeast and lactic acid bacteria.</p><p>When the company claims its single-celled protein is "free from agricultural limitations," they're not kidding. Being produced indoors means Solar Foods is not dependent on arable land, water (i.e., rain), or favorable weather.</p><p>The company is already working with the European Space Agency to develop foods for off-planet production and consumption. (The idea for Solein actually began at NASA.) They also see potential in bringing protein production to areas whose climate or ground conditions make conventional agriculture impossible.</p><p>And let's not forget all those <a href="https://www.bk.com/menu-item/impossible-whopper" target="_blank">beef-free burgers</a> based on pea and soy proteins currently gaining popularity. The environmental challenge of scaling up the supply of those plants to meet their high demand may provide an opening for the completely renewable Solein — the company could provide companies that produce animal-free "meats," such as <a href="https://www.beyondmeat.com/products/" target="_blank">Beyond Meat</a> and <a href="https://impossiblefoods.com" target="_blank">Impossible Foods</a>, a way to further reduce their environmental impact.</p>
The larger promise<img type="lazy-image" data-runner-src="https://assets.rebelmouse.io/eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpbWFnZSI6Imh0dHBzOi8vYXNzZXRzLnJibC5tcy8xOTk0MDI0MS9vcmlnaW4uanBnIiwiZXhwaXJlc19hdCI6MTY1NjU4MTg2OX0.7dZZYT5WEV_EupBuLVFwHynarTiz8RYR9aJtC6Ts2C4/img.jpg?width=980" id="3415d" class="rm-shortcode" data-rm-shortcode-id="2e6eebe06d795f844752f9e9d30040d7" data-rm-shortcode-name="rebelmouse-image" />
Image source: Solar Foods<p>The impact of the beef — and for that matter, poultry, pork, and fish — industries on our planet is widely recognized as one of the main drivers behind climate change, pollution, habitat loss, and antibiotic-resistant illness. From the cutting down of rainforests for cattle-grazing land, to runoff from factory farming of livestock and plants, to the disruption of the marine food chain, to the overuse of antibiotics in food animals, it's been disastrous.</p><p>The advent of a promising source of protein derived from two of the most renewable things we have, CO₂ and sunlight, <a href="https://solarfoods.fi/environmental-impact/" target="_blank">gets us out of the planet-destruction business</a> at the same time as it offers the promise of a stable, long-term solution to one of the world's most fundamental nutritional needs.</p>
Solar Foods' timetable<img type="lazy-image" data-runner-src="https://assets.rebelmouse.io/eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpbWFnZSI6Imh0dHBzOi8vYXNzZXRzLnJibC5tcy8xOTk0MTEzMS9vcmlnaW4uanBnIiwiZXhwaXJlc19hdCI6MTU5OTU1OTMwMn0.wnXh56iO_77x2XKV2uIPf78BKw4AJLUpmiyq_JBVGvo/img.jpg?width=1245&coordinates=172%2C146%2C62%2C135&height=700" id="0297c" class="rm-shortcode" data-rm-shortcode-id="125c9a98ec818f5c241fa28ef1423e67" data-rm-shortcode-name="rebelmouse-image" />
Image source: Lubsan / Shutterstock / Big Think<p>While company plans are always moderated by unforeseen events — including the availability of sufficient funding — Solar Foods plans a global commercial rollout for Solein in 2021 and to be producing two million meals annually, with a revenue of $800 million to $1.2 billion by 2023. By 2050, they hope to be providing sustenance to 9 billion people as part of a $500 billion protein market.</p><p>The project began in 2018, and this year, they anticipate achieving three things: Launching Solein (check), beginning the approval process certifying its safety as a Novel Food in the EU, and publishing plans for a 1,000-metric ton-per-year factory capable of producing 500 million meals annually.</p>
The protein powder Solein. Image source: SOLAR FOODS
SEAL training is the ultimate test of both mental and physical strength.
- The fact that U.S. Navy SEALs endure very rigorous training before entering the field is common knowledge, but just what happens at those facilities is less often discussed. In this video, former SEALs Brent Gleeson, David Goggins, and Eric Greitens (as well as authors Jesse Itzler and Jamie Wheal) talk about how the 18-month program is designed to build elite, disciplined operatives with immense mental toughness and resilience.
- Wheal dives into the cutting-edge technology and science that the navy uses to prepare these individuals. Itzler shares his experience meeting and briefly living with Goggins (who was also an Army Ranger) and the things he learned about pushing past perceived limits.
- Goggins dives into why you should leave your comfort zone, introduces the 40 percent rule, and explains why the biggest battle we all face is the one in our own minds. "Usually whatever's in front of you isn't as big as you make it out to be," says the SEAL turned motivational speaker. "We start to make these very small things enormous because we allow our minds to take control and go away from us. We have to regain control of our mind."