Importance of Coding Standards

Programming Help for Beginners

We write programs to instruct computers. When programming using a high level programming language like C++ or Java, we are using a syntax that is somewhat closer to human languages. However, we use these programs as inputs to either compilers or interpreters to be converted to computer understandable binary format. For this reason, as far as the program code adheres to the syntax of the used programming languages, the compilers and interpreters never bother about the layout or visual formatting of the program code. However, as human programmers, we ourselves need to bother about the aesthetics of the program code.

What is a Coding Standard?

A coding standard is a set of guidelines, rules and regulations on how to write code. Usually a coding standard includes guide lines on how to name variables, how to indent the code, how to place parenthesis and keywords etc. The idea is to be consistent in programming so that, in case of multiple people working on the same code, it becomes easier for one to understand what others have done. Even for individual programmers, and especially for beginners, it becomes very important to adhere to a standard when writing the code. The idea is, when we look at our own code after some time, if we have followed a coding standard, it takes less time to understand or remember what we meant when we wrote some piece of code.

Coding Standards Make a Difference

Look at the following example:

int volume(int i, int j, int k) {
int vol;
vol = i * j * k;
return vol;
}

Looking at this code at a glance, it takes some time for one to understand that this function calculates the volume. However if we adhere to a naming convention for variables and method names, we could make the code more readable.

Here are few sample conventions:

  • use meaningful variable names
  • use verbs in method names
  • use nouns for variables
  • use 4 spaces to indent
  • int calculateVolume(int height, int width, int length) {
    int volume = 0;
    volume = height * width * length;
    return volume;
    }

    It takes more time to type this code, however this saves far more time. This code is far more readable than its original version. With a little bit of effort, we could make the code much more understandable.

    The Benefits

    It is not only the readability that we get through a coding standard in programming. Writing more secure code could also be encouraged through a coding convention. As an example, in C++ we could say that each pointer variable must be initialized to NULL.

    char* myName = NULL;

    This ensures that we would not corrupt memory while using this pointer variable.

    Code readability is just one of the aspects of maintainability. Coding standards help a great deal with program maintainability, our ability to change programs with ease. Consistency imposed through a coding standard is a key factor to achieve success in maintaining prorams.

    Defining Your Own Coding Standard

    A programmer can define his or her own coding convention and adhere to that in writing programms. However there are many coding conventions available on the Internet. Those who program in Java should have a look into http://java.sun.com/docs/codeconv/html/CodeConvTOC.doc.html - Code Conventions for the Java Programming Language by Sun.

    For C++ coding standards, I would recommend that you have a look into http://www.bbc.co.uk/guidelines/webdev/AppB.Cpp_Coding_Standards.htm - C++ Coding Standards from BBC.

    http://oopweb.com/CPP/Documents/CPPHOWTO/Volume/C++Programming-HOWTO-14.html - C++ Programming HOWTO has some C++ Coding Conventions and also a bunch of links that lead to several coding standards that you can pick from.

    John Dirk
    Programming Consultant
    http://www.programminghelp4u.com/
    Programming ( Assignment / Project ) Help

    non-toxic cleaning company Bannockburn ...
    In The News:

    Cleverbridge says hackers copied card numbers, expiration dates and CVV codes in a data breach, and it offers credit monitoring to affected cardholders.
    Theia3D uses markerless motion capture to study how walking changes with age, tracking joint movement in older adults wearing everyday clothes.
    Citi's updated banking agreement warns that actions by third-party AI agents may be treated as authorized by you, even after a hack leaks your credentials.
    Uber Kids lets children as young as 10 ride alone in a pilot across Austin, Nashville and Madison, with live video, PIN verification and RideCheck alerts.
    Kurt "CyberGuy" Knutsson explains why stolen data can resurface years after a breach, plus tips on free credit freezes and password managers.
    Sean Duffy flew a $148,000 Jetson One solo over NASA's Kennedy Space Center. Two days later, five eVTOLs flew in formation at a public airshow.
    Stay up to date on the latest AI technology advancements and learn about the challenges and opportunities AI presents now and for the future.
    An AI bionic eye trained on a blind man's brain responses helped UC Santa Barbara researchers produce more predictable phosphenes with less current.
    A researcher claims Google Gemini pulled private Gmail billing details into chats, and Google confirms some connected-app data may face human review.
    Housefishing scams use AI real estate photos to fool buyers. Google Lens reverse image search and live video walkthroughs can help expose the fakes.
    Data brokers may expose your name, home address and phone number to scammers sending fake USPS delivery texts ahead of the Black Friday shopping rush.
    Remus Stealer malware developers claim Gmail access survives a password change, but Google says the attack targets infected devices, not a Gmail flaw.
    Palmer Luckey says SLAB, his floating industrial city, would last 1,000 years, hosting metal processing and oil refining beyond California rules.
    United Airlines is blocking unauthorized AI travel agents from its booking systems, warning that automated purchases could put MileagePlus miles at risk.
    Apple's macOS 27.3 beta 2 adds new Mac security controls for AI agents, letting you pick specific protected folders instead of granting Full Disk Access.
    Google's AI used smartwatch sensors to spot hypertension without a blood pressure cuff, but the Nature study found it missed about 1 in 3 cases.
    The FBI warns the ARTEX AI hacking tool can give criminals privileged access in under three hours, targeting Microsoft 365 and financial firms.
    The FDA-authorized Virtuoso Endoscopy System uses needle-sized robotic arms to remove bladder tumors intact, helping pathologists assess detrusor muscle.
    Identity theft restoration involves credit freezes, fraud alerts and disputing fraudulent records. Here's how the recovery process works, step by step.
    Genesis AI raised $500 million to expand its general-purpose robot Eno, which learns physical skills from workers wearing special electronic gloves.
    JPMorgan Chase says hackers accessed marketing data at third-party vendors as an extortion group leaks records tied to Visa and Mastercard customers.
    Uber Parking launches in 15 U.S. cities after the SpotHero deal, offering upfront prices, Uber One credits, and a future role for robotaxis in garages.
    The Fox News AI Newsletter covers the latest artificial intelligence technology advancements, including the challenges and opportunities AI presents now and for the future.
    Microsoft Outlook flaw CVE-2026-124194 lets a malicious .msg file expose NTLMv2 authentication data, and Microsoft confirms hackers already exploited it.
    Former Secret Service cyberfraud investigator Jason Brown warns AI voice cloning scams could trick families into losing thousands of dollars this holiday season.

    Implementing Microsoft CRM: setup and configuration ? notes for IT specialist

    Microsoft Business Solutions CRM is web-based CRM application, deploying all... Read More

    Brand Your Websites URL With a Favicon

    Have you ever noticed that when you look at your... Read More

    Microsoft Great Plains: Getting New Users Licenses ? Annual Service Plan FAQ

    Microsoft Business Solutions Great Plains, Solomon, Navision, Axapta, Microsoft CRM... Read More

    Twelve Things You Should Know to Save on Computer Software

    Do you want to get quality software at a reasonable... Read More

    Software Automation Helps Increase your Bottom Line

    When you own a small business, time is money. And... Read More

    An Easy Way to Deal with Email Viruses and Worms

    If you feel intimidated when someone tries to teach you... Read More

    ERP System of the Future: Database, Business Logic and Interface

    We will base our prognosis on our Microsoft Business Solutions... Read More

    Lotus Domino: Reports and Connectors ? Crystal Reports, XML, ODBC/JDBC, OLE

    Lotus Notes Domino is very efficient in electronic document workflow... Read More

    QuarkXpress Tips: How to Move Content Between Print and Web Layouts

    Since its release in 1987, QuarkXpress had made an immediate... Read More

    Microsoft Great Plains Nationwide Remote Support

    ERP Consulting industry is on the way to serve clients... Read More

    40/sec to 500/sec

    IntroductionSurprised, by the title? well, this is a tour of... Read More

    String in Java

    Handling character strings in Java is supported through two final... Read More

    Microsoft Great Plains eCommerce ? Stored Procedures Approach

    Since Version 8.0 Microsoft Business Solutions Great Plains & Great... Read More

    A Guide To Purchasing Professional XP Icons Online And Enhancing Your Applications

    Icons are used everywhere; right from software applications, to internet... Read More

    ERP Consulting: Microsoft Great Plains Partner Future Directions

    In the Clinton era the status quo was simple: you... Read More

    Is Your Small Business Ready For A CRM Software Solution?

    I have yet to see a business that, sometimes in... Read More

    What is Groupware?

    Vince Lombardi once said that, "The achievements of an organization... Read More

    Microsoft CRM Integration with IBM Lotus Notes Domino ? Machinery Dealership Example

    IBM Lotus Notes with Domino email server is traditional document... Read More

    Microsoft Great Plains Jewelry ? Implementation & Customization Overview

    Each Industry and market niche has business specific and unique... Read More

    Microsoft CRM Implementation & Customization: MS CRM Fax Gateway

    With this small article we are continuing Microsoft Business Solutions... Read More

    10 Things You Could be Using Photoshop For, But Probably Arent

    Most people don't use Photoshop to its fullest capabilities. Here... Read More

    Linux Dual Boot-How To Format

    Just the thought of a duel-boot scares many people away,... Read More

    Exactly What Does FTP Stand for and What Can it do for Me?

    FTP stands for "file transfer protocol". FTP is basically a... Read More

    Snort for Network IDS

    What is Snort?Snort is an open source network intrusion detection... Read More

    Great Plains Dexterity Programming ? Overview For Developer

    Looks like Microsoft Great Plains becomes more and more popular,... Read More

    maide service in Morton Grove ...