•February 5, 2015 • Leave a Comment
INTRODUCTORY PROGRAMMING CLASS DISCUSSION BOARD ARTICLE
“Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live. Code for readability.” – John F. Woods
In order to have your code respected and appreciated, it need not only to be efficiently programmed and well constructed but also well written and well formatted! Yes, not having bugs is essential and of primary importance; however, what good would it be if it can only be poorly understood, barely maintained, or hardly developed?! A professional programmer always keep the code clean, formatted, and well commented.
… Though one may question these factors as how their style is made or picked. Well, there are conventions and defined styles for almost everything: variable and function naming, indentation, and even commenting. When programmers worked on large projects, they’ve noticed that abiding a convention or a standardized style always ease up the development process and understandability of code written by different coders.
Continue reading ‘Writing Code in a Professional Manner’
•February 2, 2015 • Leave a Comment
Note: don’t get too excited, I’m not back to blogging. I’m writing some articles for a basic programming class discussion board and I may share some here.
When a team embarks on a new project to develop, one of the first decisions they make is the choice of a programming language which is typically based on the type of application they’ll be building. Ever since Java became popular and up until the middle of the last decade Java was almost always the pick for systems whenever the target application needed to be portable. I will not discuss what other languages and technologies they use now, but rather I will discuss how Java has always been seen as first pick for portability and how it shouldn’t; I will investigate the portability of the C language and compare it to that of Java.
Continue reading ‘Java vs C portibility – intermediary code perspective’
•October 14, 2011 • 2 Comments
Yesterday. … It’s the day that precedes today. It’s also the day Ubuntu released Ubuntu 11.10, the day I knew about the death of Dennis Ritchie, and the day I wrote a C program as a tribute to Dennis’ death and made me and my PC suffer!
Well, I was at college most of the day – with no internet connectivity; it remained that way till I returned home late at night. Like always, I check emails and RSS. Q8Geeks.org had a new post: Dennis Ritchie RIP.
I was not expecting his death, … it was a shock; I actually was sad. Being tired, I thought I should sleep. However, right before I got off my chair, I decided to write a C program as a tribute to Dennis’ death; I was inspired by GH0S1_R33P0R’s code in the blog-post.
Click to see how the tribute resulted in a nightmare!
•September 11, 2011 • 3 Comments
Imagine this situation: you’re supposed to give your supervisor an important report he’s expecting on a specific day, on that day you give him a bunch of blank papers. He garbs the papers and goes through them as his anger increases. He awaits an explanation and you say: … You see, it’s whitespace encoded.
You know, that situation is not far from the situation that brought up this topic! The other night, sigtermer and I were talking about our programming class professors and how one can effectively have his revenge on them for being – let’s just say: not so open-minded – professors. A thought rolled after another, then this idea kicked in. Giving a professor the requested code – whitespace encoded. Handing him the blank papers would yield the best expression ever. Explaining it would confuse him whether to be angry of this joke or be interested and ask about the codec. Doing that to dino-professors would probably result in deducted marks instead of few extra ones! Though I think it would be worth it.
Putting those situations aside, how does the the idea “whitespace
encoding” sounds to you? Sounds fantastic to me!
Click to read about the evolution of the idea!
•September 10, 2011 • 198 Comments
Android disapproves Wifi *
Ever since I bought my android phone, iGalaxy (Samsung Galaxy S), it grew to hate me more and more until the beginning of this year; it had enough. Little Android finally refused to work accordingly. Until recently, I’ve been suffering of an irritating issue. But honestly, I don’t blame it for what it has done, I hate it; it’s only natural to hate back whoever hates you.
The issue that I was facing was a Wifi issue: a bug that renders the phone incapable of connecting to a specific wireless network! Yes, it would connect to other wireless networks except a specific one. Unfortunately, in my case the specific wireless network was my home wireless network. This issue is known as: Wifi obtaining IP address issue.
Note: If you are searching for a workaround, go watch the video at the end. Also, check the update section in the end of the blogpost. Comments might also help.
If you wish to continue reading the post click this link!
•August 27, 2011 • 4 Comments
Original screenshot by Kai
Have you ever wondered what phone number you should get? Have you ever wondered what your phone number might spell? … Well, I had to dive into this since I’ve been thinking lately of ditching my current Telecommunication Service Provider for another one – seeing that another TSP charges less and provides longer validity.
Now, when people here in Kuwait decide to get a new phone number, the majority goes for what they call “golden lines”: phone numbers that contain as few different digits as possible and as structured as possible (e.g. xxxyxxxy). The only problem with those numbers is that they are extremely expensive – some reached above 1000KWD! But honestly, even if they were not as expensive, let’s say as cheap as the regular phone numbers, I wouldn’t be that interested.
However, what interests me is phone numbers that actually spell words; phonewords; vanity numbers (e.g. xyz-NUT). This is uncommon in here, in fact, I’ve yet to meet someone that spells his phone number! Objectively, I dislike this fact, but subjectively, I love it; it means we, those who seek phonewords, have a greater chance to get what we want! … That’s why I had to know what numbers some great names would correspond to on dialpads.
At first, I grabbed my phone and manually translated the words I had in mind. All one has to do is looking up the corresponding number of a letter on a dialpad. GNU:468; linux:54689; debian:332426; ubuntu:828688; python:798466. However, upon finishing that, a bunch of other names came to my mind. I couldn’t take it, so much unnecessary effort has been put. I decided to write a script.
If you wish to continue reading the post, click this link!
•August 17, 2011 • 3 Comments
“Google”, every human being knows this name and for what it stands for – except for some Kuwaitis who mistake it for the internet. “Googol” on the other hand is a fairly known word, probably only professors, nerds, and few geeks know it. Those two words are close in spelling that one can easily misspell one of them. In fact, the Internet approves this possibility and suggests that one should believe Google Incorporation’s claim:
“Google” is a misspelling of the word “googol”.
However, I had to investigate; I ended up with my own unique hypothesis.
Click to read my bizarre valid hypothesis!