So it’s my fifth round of the 100 days of code challenge and I really want to take a big step forward. Since completing the first round I haven’t made any significant changes to my approach towards the challenge. For this round of the challenge I start by adding blogging to my daily requirement.
Blogging my coding activities may not seem like much but to me it is. I mean 100 days is not a joke, and, it’s difficult enough for me to stay consistent with coding everyday for at least an hour. I have a lot of other ideas but I have found that when I place too many targets to take aim at, I will tend to miss more than I actually hit. So for now I will just try to blog. The first 21 days of the challenge will be the most difficult for me (I think that’s how long it takes to build a habit).
So what did I do today?
Piggy backing off of Day 100 in Round 4, I started working on the exercises for lecture 2 of the MIT Computer Science Missing Semester Course. I started on question #1 and decided to try and write some API/docs types of notes while I was answering it. The question was:
- Read
man lsand write anlscommand that lists files in the following manner- Includes all files, including hidden files
- Sizes are listed in human readable format (e.g. 454M instead of 454279954)
- Files are ordered by recency
- Output is colorized
A sample output would look like this:
-rw-r--r-- 1 user group 1.1M Jan 14 09:53 baz
drwxr-xr-x 5 user group 160 Jan 14 09:53 .
-rw-r--r-- 1 user group 514 Jan 14 06:42 bar
-rw-r--r-- 1 user group 106M Jan 13 12:12 foo
drwx------+ 47 user group 1.5K Jan 12 18:08 ..
So I wrote some notes on the ls command in the shell. Besides that, I reorganized some of my notes on tech interview prep and tried to prepare my process for the challenge these next 100 days will present. Here was my solution for the exercise.
$ ls -alt --block-size=M --color=always
-t= sort by modification time, most recent first-l= long listing format-a= show all files (including hidden)--block-size=M= show file size in Megabytes instead of bytes (which is the default).--color=always= have the output be colorized.
I will try not to write too much to start so that I pace myself. Speaking of which I guess I should stop here… Until tomorrow (I hope). PEACE!