15 Good Programming Habits

1. Before sitting down for coding, you must have formal or a paper-napkin design of the solution to be coded. Never start coding without any design unless the code is trivial one.

2. Good code documentation is as important as good knowledge of a programming language. Write brief logic for each major block of your code as comments in source code file itself. Its good to mention creation and modification dates of your program along-with why modification was required.

3. Maintaining versions of your program is another important task. Some present-day programming tools already have a built-in version management. Whenever you make any change to your program, they save its copy as .bak file.

My approach is to maintain 3 versions of a program. Say, I have a file program.c which is used by other project team members also. I copy this file as program.c.old as backup and make another copy as program.c.wrk where I do modifications. When modifications are successfully compiled, replace program.c with .wrk file.

You can also append a date or some explanation phrase to your program versions like program260505.c or programReadFnWrking.c .

4. If your project contains multiple source files then maintain a README file stating purpose of each source files, data files, intermediate and log files (if any). You may also mention the compilation and execution steps.

5. Ever wondered why your IF statement is not working as it should do. May be your are using single equal i.e. "=" instead of "==" in the condition check. A good approach is to write condition in reverse order. So, your condition should read something like this:

if ( 10==i) .... So, if you put single equal sign by mistake then it will be detected at compilation time only as an error.

6. While using loops and conditional statements, always first put closing braces corresponding opening braces and then write the inner statements i.e.

1) for(int i=0;i

shuttle from Midway Glen Ellyn ..
In The News:

Stay up to date on the latest AI technology advancements and learn about the challenges and opportunities AI presents now and for the future.
Emails instructing you to reset your password for an account may be legitimate, or they may be scams. Kurt "CyberGuy" Knutsson explains.
Northrop Grumman's Manta Ray uncrewed underwater vehicle aims to revolutionize undersea missions — it glides through the ocean without human assistance.
Learn how to work Google's calendar application to streamline and organize your daily tasks from technology expert Kim Komando.
If you do not want Facebook to have automatic access to your private photos, follow our tips to protect yourself. Kurt “CyberGuy" Knutsson shows you how.
Kurt “CyberGuy" Knutsson goes into detail about Apple’s recent iOS update that allows iPhone users to instantly translate spoken language simply by using the Action Button.
Safeguarding your digital life with a reliable physical backup isn't just a precaution, it's a necessity. Kurt “CyberGuy" Knutsson provides the essential backup checklist.
Kurt “CyberGuy" Knutsson reveals how a Redditor exposed false recycling claims at their apartment, highlighting a report that only 21% of U.S. recyclables are processed.
Kurt "CyberGuy" Knutsson offers a travel toolkit featuring five technology tools to help you with booking flights and hotels for your summer vacation.
The bubble behind the clock on your iPhone can appear in different colors. Kurt "CyberGuy" Knutsson explains what each of those colors mean.
Scammers are using the power of artificial intelligence to mimic voices of people and are using the fake voices to commit crimes, like kidnappings.
Stay up to date on the latest AI technology advancements and learn about the challenges and opportunities AI presents now and for the future.
Tech guru Kurt "CyberGuy" Knutsson explains the science behind the Invisibility Shield, a 6-foot shield that makes people become invisible.
The International Olympic Committee on Friday announced plans to use AI in various Olympic aspects, including athlete identification, training and judging.
Tech guru Kurt "CyberGuy" Knutsson explains an easy trick to avoid squinting while working or surfing the web by zooming in on your personal computer.
Streaming giant Roku has recently been targeted by a pair of cyberattacks, and the company confirmed over a half million Roku accounts were compromised.
The Land Aircraft Carrier combines an all-terrain, six-wheeled vehicle with a two-seat aircraft, which features electric vertical takeoff and landing.
The European Union has sent TikTok a "request for information" on the video sharing platform's newest app, TikTok Lite, under the Digital Services Act, with the aim to clean up social media.
Stay up to date on the latest AI technology advancements and learn about the challenges and opportunities AI presents now and for the future.
The FBI is warning the public about a recent phishing scam via text that claims its targets owe money in Pennsylvania for unpaid road toll charges.
Your Apple Music settings may be revealing to your contacts what you're listening to. Kurt "CyberGuy" Knutsson explains the process to change those settings.
Learn how to secure social media accounts, implement legacy contacts, and create a digital estate plan to protect your online assets from 'ghost hackers' after your death.
A ported phone number scam is leading to more people having their identities stolen by sophisticated scammers. Kurt “CyberGuy" Knutsson tells you what you need to know.
The Great Pacific Garbage Patch, a vast marine debris vortex, is being tackled by The Ocean Cleanup’s innovative technologies. Kurt “CyberGuy" Knutsson explains.
Discover easy solutions to tame autocorrect frustration on iOS and Android devices. Turn off, customize and add personal touches to your typing experience.

Help, I Need a New HDTV! (Part 1 of 5)

Feeling overwhelmed in selecting a new TV? With all the... Read More

Get Ahead When You Build Your Own Computer

If you've been kicking around the idea of building your... Read More

4 Computer Money-saving Tips

Tip #1 -- Rebates: A rebate is not always a... Read More

Protect Your PC from Viruses, Worms & Trojans

Each of the items in the checklist below is part... Read More

EDTV vs HDTV

Confused by EDTV vs HDTV? We don't blame you. The... Read More

Best PC Pocket GPS

Stop Getting LostOne of the greatest uses for a pocket... Read More

Your Affiliate Business - Peripherals, Software, Computers

I have always been interested in computers, but in the... Read More

How to Buy a Plasma Television Set

Most people think that all you have to do to... Read More

Registry Tools Demystified

Not sure what Windows registry is or how it works?... Read More

Compile .BAT Files into Native Windows Applications (.EXE)

Since the DOS days, batch files have been one of... Read More

Three Things You Can Do to Keep Your Computer Running at Maximum Performance

Although there are many things that can affect the performance... Read More

This Page Cannot Be Displayed ? What to Do When Your Internet Breaks

The DNS (Domain Name System) servers are what your computer... Read More

Basic Computer Thermodynamics

That desk in front of you and everything else around... Read More

SmartCar Memory Stick for LapTop Transfer Data

With the new technology used to transfer information to from... Read More

Deleting and Destroying Data Forever

Peoples' private information needs to stay private, even after it... Read More

Tips for Buying a PC

Buying Your PCBuying a PC that's right for you and... Read More

Getting Started with HTML

The basic language of the internet is html. If you... Read More

The Help Desk

When you think of a help desk, what do you... Read More

Is Your Web Browser Putting You At Risk?

It's free, it comes with Windows and it's used by... Read More

Got Virus?

GOT VIRUS? Your Data is NOT lost forever!In the wake... Read More

Internet Explorer Shortcuts for Mouse-o-phobes

If you're like me, you occasionally find the ubiquitous mouse... Read More

Maintain Your Computer ? Keep Your Business Running

Maintaining your computer is extremely important ? especially if you... Read More

Cisco CCNA Certification: Five Things To Do DURING The Exam

There are plenty of articles out there about how to... Read More

Consumer Electronic Information: The Basics of the DLP Projector

Projectors have come a long way in the past few... Read More

Quick System Restore with ASR Backups

ASR (Automated System Recovery) is a feature available on the... Read More

shuttle from O'Hare North Chicago ..