Thursday, November 28, 2019

Learn Practical Programming - Code Gym @ Kuchai


Code Gym - Practical Programming 

If you're interested to equip your child with practical programming skills for the job of tomorrow, then what better way than to learn from those who have actually used those skills at work and have the experience and know-how in using the latest technology to solve today's problems. 



Link above, take a look. Learning to code to solve practical problems should not look like an unattainable goal. In fact, it is attainable with the right guidance. Let Code Gym open your eyes to a whole new world where you'll learn the meaning of 'possibility'!


Monday, October 21, 2019

Learning Loop

Learning Loop

Our capacity to learn, break it down (unlearn), re-learn and iterating that cycle to continuously improve...is always there. 

We have been doing it all our lives, from the day we are born. 

We didn't know how to sit, now we do.
We didn't know how to stand, now we do.
We didn't know how to walk, run, jump...now we do.
We didn't know how to talk, now we do.

We don't know everything, but we know we can learn. 

Friday, October 18, 2019

Feel Great by Taking Action

Feel Great by Taking Action

I'm feeling great today. I feel so energetic. I feel close to being in the zone. 

It is very rare that I feel like this. Usually it is mellower, meaning I have to be more aware, and plan better to feel slightly more energetic. My thought processes are not laborious, even though I am executing a task which usually need much motivation to get through, I just slice through the 'resistance' (to borrow the meaning from Steven Pressfield), which feels great. 

The thought ran through my mind to take this unique opportunity and reflect what I thought went right prior to this 'feeling'. So here goes in no particular order:

1. I had 7hrs of sleep the night before. I have found that I function best with minimum of 7 hours sleep. I am just surviving with 6 hours. 
2. I woke up at 5am to work on personal 'work'. I didn't complete it but I got something done. 
3. Because I woke up earlier, I was able to have a less rushed time getting myself and my kids ready. 
4. I had breakfast and coffee. 
5. I had planned what I wanted to work on (on a macro level) at work today. 
6. I was listening to Seth Godin on Tim Ferriss's blog. My mind was processing that interview for a few days. 

Listening to people with more experience and willing to share those experience and listening to their thought processes is a great method to understanding ourselves better. It has certainly helped me. Hope it helps you too. 

You can do it, take care, have a great day. 

Wednesday, October 16, 2019

Taking Initiative and Not Afraid to Fail While Doing It

Taking Initiative 

and 

Not Afraid to Fail While Doing It

I'm referencing Seth Godin's blog post on initiative. I contemplated going beyond just sharing a useful tool to my boss. As in, to start putting content inside, codes, suggestions, links and so on. I was afraid it would amount to nothing, as in, it will not be useful for the team. Then I thought about what Seth wrote about this topic and that's it, he is totally right.

If we thought about the things we thought about doing which had a spark of creativity, a spark of hope but then we pulled back due to fear of failure and rejection. It has happened to me so many times. Sometimes I pull back, I may have thought the stakes was too high. Sometimes I go ahead, when I have given it some thought and well, there was nothing to lose except some ego (which no one really cares about...most people care mostly for themselves), and sometimes it works out and sometimes it don't. However, I walk away with so much more insight to how I function and how I interact with the people around me. It is so interesting, but then so scary at the same time...which funny when I think about it, I feel so happy.

So there it is, I made a decision to just start putting content into that tool. Codes, suggestions, brainstorms, articles, whatever...

https://seths.blog/2019/10/initiative/

Monday, October 14, 2019

Raspberry Pi 4 Model B 4GB - Arrival

Raspberry Pi 4 Model B 4GB - Arrival

I have been window shopping for a Raspberry Pi to play with but did not commit to any purchase. In my area, a Raspberry Pi 4 Model B (4GB) retails for approximately RM269 (USD64) to RM299 (USD71). I was happy with the projects I have on-going (in my case, long term, half-finished, only work on it when I have ample free time) with Arduino Nanos. So I told myself that I do not need another project at the moment. 

So just a few days ago, there was a sale on 10th Oct (1010 sale). I have been receiving almost daily emails from this online electronic marketplace which to be honest irritated me. I was clearing my inbox when I was curious what this 1010 sale was all about and turns out it was my lucky (or unlucky - says my wallet) day that there was going to be an additional RM30 discount on the Raspberry Pi 4! 

I bought one and now its on my desk. Kind of surprised it looks much smaller than what I'd thought it would be. 





It is so easy to buy electronic parts and have so many project ideas but completing one is ever so hard...sigh. 

Friday, October 11, 2019

I can F.E.E.D on Good and Bad Days

I can F.E.E.D on Good and Bad Days


There are days when I am feeling at the top of the game. All my faculties are performing on point. I wake up clear headed with enough rest, get started on my morning routine without a hitch and when I'm out the door I am ready to take on the traffic. When I reach the office, I tackle each task with enthusiasm and efficiency. By the end of the day I feel as energized as when I reached the office. 

On days like these, I feel I could accomplish anything. I could put my head into my goals, work on the mini goals to get to my long term goals. Any challenges that comes in the way would not feel like a wall but merely a puzzle to figure out in order to move on to the next item.

Other days are not so great. If I did not get a good nights rest, or the day somehow started off badly, then somehow my energy levels will not be that high. I would struggle to get started on what I need to get done. I would procrastinate and get distracted by emails or social media.

It was frustrating. Especially when there is a realization that you could have done things better or get that particular task cleared off your plate. At times like this, I push myself and say to myself, I can get through this day. I can do it, I just need to start. I can F.E.E.D - Focus. Effort. Effortlessness. Determination. F.E.E.D definitely helped me with my energy and motivation as well as many parts of my life. F.E.E.D is from Rewire Your Brain a book by John B. Arden that helped me understand more about my brain and how it works and how I can rewire it. It led me to other books and articles. Couldn't have done what I have done without this book. Or it would have took me longer. 

Monday, October 7, 2019

Getting Started with OpenMP



Getting Started with OpenMP

https://www.geeksforgeeks.org/openmp-introduction-with-installation-guide/
https://medium.com/swlh/openmp-on-ubuntu-1145355eeb2
http://deeplearning.lipingyang.org/2017/01/30/openmp-on-ubuntu/

The above links was very helpful in getting me started really quickly in getting a Hello World code up and running.

Step 0 - Install GCC compiler: I did initially was not aware if my Ubuntu had gcc installed, I read it would at least have a version of it, so I decided to just install it. I opened at terminal (CTRL+ALT+T) and keyed in the command below.


 sudo apt-get install gcc  

Step 1 (Optional) - Install OpenMP library: Once I had the gcc compiler installed, then OpenMP should already be configured in the compiler. I went ahead to install OpenMP library anyway.


 sudo apt-get install libomp-dev  


Step 2 - Setting Number of Threads:
Then next we can set the number of threads using the command below.


 export OMP_NUM_THREADS=3  

Step 3 - Hello World Code:
I have not mastered using VIM. Coming from Windows environment (don't laugh), I was more comfortable with Notepad++. Thank goodness Notepad++ is available as an application download in Ubuntu, so I used it to write a "hello world" code. Saved it in ".c" of course. 


 #include 
 #include 
int main() {
  int i;
  #pragma omp parallel
  {
   for(i=0; i<10 br="" i="">    printf("%d\n",i);
   }
  }
  return 0;
} 


Step 4 - Compile and execute: Compile and execute command. It was running! Hooray!

Compile:
 gcc -fopenmp helloworldmp.c -o helloworldmp

Execute:
time ./helloworldmp




Using another code:
#include 
#include 
int main() {
 #pragma omp parallel
 {
   printf("Helloworld\n");
 }
 return 0;
}




Ubuntu Freeze On VMware


Ubuntu Freeze on VMware

I'm running Ubuntu 18.04.3 LTS on VMware for a university project and it constantly freezes on me midway into my C coding assignment. 


Google search came to the rescue. Edited the virtual machine settings (increased memory from 2GB to 4GB, I had added 8 more GB with total memory now 16GB, so increasing to 4 should not be a problem) after reading a solution from this site.


Click on it to edit machine settings

Now problem solved and I have more hair for it. Thank you Google.

Monday, June 10, 2019

We are living a good life

In our minds, our reality is always telling us we are not doing as well as can be or as successful as others. I find myself sometimes walking with a frown on my face, figuring out how to be successful. I am always coming away tired, beaten down by the thought of how difficult it would be to be successful. It was even difficult defining what would be considered successful.

Maybe I should change the narrative. Change my reality. I'm able bodied. I have a job earning a good salary, with that salary able to pay for a house, a modest car and childcare. I have a family whom I love very much. I'm grateful for what I have. Therefore whatever I am doing next is not going to be tough. It is going to be an adventure. An adventure that will take me to meet new places, new people and learn new things.

If we really look around us, nothing is easy. All is tough. Why put our minds through that lens? Why not change that language. Yeah, life is tough. Other people have triumphed over more difficult circumstances. If we instead look and think of it as the opposite...instead life is going to be fun, adventurous, road less traveled, a wonderful world of self-discovery.

Start sowing the seed of endless energy by first changing the language, narrative and lens in which we describe our current lives.

We can do it...we can define our own success and discover our new selves.

Saturday, March 30, 2019

Fearless Facing Fears

The only way to to overcome fear of working with people who talks louder and are more authoritative is to focus on facts and do your homework before meeting them. No guarantees of coming out ahead, but if you aim for win-win, however it turns out, you will come out of it almost without an injured ego (since you're focusing on facts) but most certainly you will come out of it learning something. 

Therefore, face your fears and be fearless, with facts and due diligence on your work. Know your limits and acknowledge your weaknesses, only then you can work on moving forward and pushing your limits...being fearless.