Writing Meaningful Code

11 Feb 2021

Write your code for humans, not for computers!!

Software engineers spend a large amount of their time reading and writing codes. Maintaining specific coding standards on the code is very important because the code reader will have faster comprehension of what the code is doing and save them a reasonable amount of time. Someone may argue that the computers or compilers don’t care about the coding standard; they only care about the syntax that we use in our code, so why is there such a big fuss about maintaining the coding standard. As software engineers, we regularly collaborate with our peers to share our codes and try to work on other people’s code. A low-quality code is challenging to understand, which can be frustrating if you’re working on a project with a deadline. Furthermore, the quality of code is a measure of how diligent and professional the coder is. Hence, it is in everyone’s best interest to write well-defined code following the organization’s coding standard.

Readable code is important

In the ICS-314 class at UHManoa, my classmates and I are required to use ESlint with IntelliJ. Before using ESLint we weren’t required to maintain a specific coding standard in our code. After days or weeks of working on different assignments, if we were to review the previous code, understanding the code and functions and variables implementation took a long time. Think about it, if you were assigned a specific project with time constraints that require you to fix the code written by someone else, the last thing you want is to see the written code all over the place without proper commenting, formatting, and meaningful variables and function declaration.Having the right checkstyle plugins like ESLint is important, as it helps maintain an appropriate standard of coding.

Programmers shouldn’t overlook the importance of maintaining coding standards. As a programmer, sometimes you may have limited time to focus on one single task. Nothing can be more frustrating than spending enormous time solely to understand the variable and function implementation, which could’ve been avoided if the code was well defined. Therefore, a programmer must write clean, comprehensive, and well-formatted codes.