Menu
Alfredo Motta
  • Home
  • Newsletter
  • Articles
  • About me
  • Events
  • Books
  • Research
  • Learn to code in London
Alfredo Motta

Not So Random Software #9 – Anger Management

Posted on January 12, 2020May 18, 2022

Welcome back to Not So Random Software. This week’s links are dedicated to Anger and our relation to it. As Seneca pointed out many years ago we often suffer more in imagination than in reality. Our response to feelings of anger make all the difference to what happens afterwards and our happiness.

A random article or paper

In this article you can find a summary of the most common techniques on anger management from the ancients Stoics. Personally I find focusing on what you can control versus what is out of your control one of the most useful and liberating ideas, followed by gretefulness.

A random video or podcast

In this podcast leadership coach Jim Dethmer explains how to shift from the victim consciousness, where you’re defensive and attached to proving you’re right, to what he calls the creator consciousness, where you choose to be responsible for your own experience.

A random book

In What We Really Do All Day insights from the Centre for Time Use Research are distilled to present us how really our days have changed since the 1960s. When I look at the time data it helps me detach from the problem of owning and controlling time; I shift my focus on what I can control, by choosing how I want to experience time rather then being a victim of it.

A random tool

Last year the one purchase of £10 or less that really changed my life was getting an Electric Candle Lighter. I am more inclined to light up my candles at night and they help me relax and fall asleep.

A random line of code

We project our lifes in software, and software is reflected back in the way we approach life. In this context Refactoring can be seen as a way to shift your perspecive on the world, by simplifying it a bit. Extracting methods is a surprisingly effective mechanism to do so. Here is a simple example.

Before:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
class Invoice
  # ...
 
  def print
    print_branding
 
    # print line items
    line_items.each do |line_item|
      puts "#{line_item.name}: #{line_item.price}"
    end
 
    # print subtotal
    puts "Subtotal: #{line_items.sum(&:price)}"
  end
end

After

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
class Invoice
  # ...
 
  def print
    print_branding
    print_line_items
    print_subtotal
  end
 
  private
 
  def print_line_items
    line_items.each do |line_item|
      puts "#{line_item.name}: #{line_item.price}"
    end
  end
 
  def print_subtotal
    puts "Subtotal: #{line_items.sum(&:price)}"
  end
end

A random quote

Thoroughly unprepared, we take the step into the afternoon of life. Worse still, we take this step with the false presupposition that our truths and our ideals will serve us as hitherto. But we cannot live the afternoon of life according to the program of life’s morning, for what was great in the morning will be little at evening and what in the morning was true, at evening will have become a lie.

Carl Gustav Jung

Receive this by email

* indicates required

 
 


Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Answer the question * Time limit is exhausted. Please reload CAPTCHA.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Tweets by mottalrd

Recent Comments

  • mottalrd on Not So Random Software #21 – Technical debt
  • mottalrd on Not So Random Software #24 – Climate Change Tech
  • mottalrd on A/B Testing, from scratch
  • mottalrd on A/B Testing, from scratch
  • Karim on A/B Testing, from scratch
©2023 Alfredo Motta | Powered by SuperbThemes & WordPress