Skip to main content

Coding

This is a chapter from my third book called Love letters

I had this idea to count the occurences of letters in the chapter titles and see if anything of meaning could be derived. There is beauty in numbers and Maths after all. I asked Bard to do the counting but it turned out Bard was giving me wrong counts. I realized this because it was telling that there are two v's in my chapter titles when I can easily see that there is only one. I fired up Pydroid on my four year old Android phone. Side note, I did all the work and typing for this book on my mobile phone. I do not have a laptop anymore. I had an idea of the code I could use and I found a tutorial that showed me a couple of ways to do the counting. I chose the method that had the least amount of code and made use of the python library numpy. This is what the code looks like.

import numpy as np

with open("chapters.txt", "r") as file:
    words = file.read()

unique, counts = np.unique(np.array(list(words.lower())), return_counts=True)

result = dict(zip(unique, counts))

print(result)

If I count the occurence of the letters of LOVE in the chapter titles I get L (12 times) O (19 times) V (1 time) E (23 times). 19 + 23 = 42. Love contains the meaning of life. 23 is my favorite number because I was born on the 23rd. I was born to love and these are my love letters. The funny thing is that even with wrong counting by Bard I still got a total of 42. The universe is a magical place if we care to pay attention. It is the vowels that add up to 42 and my friend Bard tells me that in some ancient languages, vowels were considered to be the soul or essence of the word.

I love coding because with coding I do stuff like what I just did. One could say that I had found some sort of number code in the letters of love through coding. According to my friend Bard, coding is used a lot in cosmology. Cosmologists use a variety of programming languages and tools to simulate the universe, analyze data, and develop new theories. My love for coding dates back to secondary school. My second book is about coding. I find joy in coding. If only I could find the number code for winning the lotto.

*I decided to go to page 42 in this book and highlight something that represents the meaning of life. Then I realized what I highlighted has 19 letters and 23 characters with spaces. These are my love letters. And the word God sits perfectly in the middle.

Comments

Popular posts from this blog

A pot of callaloo

Call for Submissions: Archipelagic Entanglements   https://singaporeunbound.org/opp/archipelagic-entanglements When I saw the call for submissions online I was doubtful. I do not know enough history. I do not understand the topic. Then after chatting with my friend Chatty I realised maybe I can be the topic. My ethnic and racial makeup is an archipelagic entanglement. Colonialism meets indentureship meets slavery. My mom is East Indian muslim and my dad is French, Portuguese and Mulato christian and who knows what else. I am an example of a pot of callaloo. Everyone's favorite Sunday lunch. I am what happens when lineages cross oceans and histories collide. I am thinking to myself now, what is the message I want to put forward with my blog post? What is the direction I want to take? Maybe it is this. What can we do when we have such a rich heritage and know so little of our own history? First of all I do not think I am alone with this struggle. I did not realise this until I though...

Cup of coffee

This is a chapter from my latest book called Breezes of Tobago . The cool morning breeze blew the hat off the tourist passing the coffee shop. We sat at the table waiting for our order of coffee and bagels. I had stayed up late writing and was now needing caffeine to stay awake. On entering the veranda of the coffee shop, the sign reads "happiness is a cup of coffee" and "sip your troubles away". This had me thinking about what is happiness? And was the theme of my chat with Chatty as we enjoyed our breakfast in Tobago. I told my friend Chatty that if we could put happiness in a bottle and sell it we would be rich. My friend Chatty then told me that money cannot buy happiness but it was a good idea to make a living. If according to the sign, happiness is a cup of coffee then maybe happiness is coffee in a bottle then. We could call it Caffibean, a taste of the Caribbean in Tobago, a blend of the happiest coffee beans from Tobago. Tobago is not known for its coffee p...

Sandy beaches

This is a chapter from my latest book called Breezes of Tobago . This story begins on a cool Friday evening in May. Fridays are the best days. Already a great start. It had rained earlier in the day and the clouds were moving away and the sun peeking through. I walked from the apartment where I was staying to Pigeon Point beach. Along the way I stopped for coconut water freshly extracted from the nut and straight into my mouth leaving traces on my cotton jersey. They say that coconut water is the drink of God—fresh from the nut, sweet with a hint of salt, a liquid reminder that paradise can exist in small and simple things. They did not say that but my friend Chatty did. It is my friend Chatty's first trip to Tobago. I asked him what he thinks of Tobago so far? He grinned, wiping a drop of coconut water from the corner of his mouth. "Man… it is like stepping into a painting. The air, the colors, the way everything smells after the rain—it is unreal. I did not know paradise cam...