Today's Question:  What does your personal desk look like?        GIVE A SHOUT

SEARCH KEYWORD -- Clean code



  Clean Code Versus Great Code

I've had some interesting discussions with other developers about writing code recently. I often have the impression that some developers put too much emphasis on clean code. Don't get me wrong, i strive for clean code as well, and have written about its importance quite a lot in the past couple of years. But when i'm coding, clean code is my secondary goal and it could never take the place of my primary goal: making it work. And preferably, i want to make it work great. A lot of people love t...

   Code,Clean,Excellent,High quality,Compar     2011-08-10 03:27:08

  Why no max/min function for integer in GoLang

You may notice that there is no max/min function provided to compare the maximum/minimum of two or more integers if you are a GoLang developer with some experience . In other languages, these functions are provided as part of the core lib functions. Have you wondered why?  Indeed GoLang provides max/min function in math package, but they are used for comparing float64 data type. The signature of these two functions are math.Min(float64, float64) float64 math.Max(float64, float64) float...

   GOLANG,MAX,INT,INT64     2019-06-08 07:00:55

  Remote form submission

Remote form submission is way of submitting HTML forms from local to a particular remote server. This is used by many advertisers, spammers or even hackers to submit bad data to other websites in order to get what they want. They can write some automation scripts to help them do spamming. How can people do remote form submission and how to prevent this kind of attacks? Since a website can be accessed by almost every one, so one can save a local copy of a HTML form of a website through File->S...

   PHP,Security,Remote form submission     2013-07-14 01:04:49

  malloc/free and new/delete in C++

malloc and free are C++/C language standard library functions, while new/delete are operator of C++. They can be used to allocate dynamic memory and free memory in C++ programs malloc/free can not meet the requirements of dynamic objects creation. Object needs to call the constructor to initialize the object when creating, the object needs to call the destructor before it is destroyed  Since malloc() and free() are library functions rather than operators, the compiler has no control permiss...

   C++,memory,malloc,free,new,delete     2012-06-20 06:52:09

  Is coding going to die?

There is always a voice recent years saying that coding will gradually die, software development is more like an assembly job. i.e, programmer will be more and more like IT engineers. They seldom build something from scratch, instead they achieve the goal by assemble different components. There are people who have similar views around me. From the book "Clean code" written by Robert C Martin-- "One might argue that a book about code is somehow behind the times—that code is no longer...

   Coding,Clean code,Disappear,Analysis     2012-03-15 14:37:35

  HeartBleed: OpenBSD now starts to clean up OpenSSL

Since the disclosure of HeartBleed bug in OpenSSL, some arguments emerge around the safety of OpenSSL, the largest open source SSL/TLS library used by large number of servers, applications. Some people are even starting to create their own version of SSL library. This includes OpenBSD, a famous Unix like open source operating system. Just a few days after the HeartBleed bug, OpenBSD forked a new branch of OpenSSL and started to clean up the forked branch and plans to merge it to its own cod...

   HeartBleed,OpenBSD     2014-04-15 04:21:26

  Google starts to clean up its service again

Google announced on its official blog that they would clean up its service again following the fall of 2011. They will close some features and services to stay focused and make good use of other opportunities.Google Reader and Snapseed are listed in the cleaning list. Google will switch off Google Reader on July 1 this year and end its service which exists in the past eight years, Users can export feeds using Google Takeout. Google said that this product did have loyal customers, but these year...

   Google, Google Reader,Close     2013-03-13 20:30:34

  Mastering Async/Await in JavaScript: A Comprehensive Guide with Examples

As a veteran JavaScript developer, I have seen the evolution of JavaScript's asynchronous programming landscape. From callbacks to promises and now async/await, JavaScript has come a long way in making it easier to handle asynchronous operations in a clean and readable manner. In this article, we will delve into the world of async/await and explore why it has become a popular choice for handling asynchronous operations in JavaScript. We will cover the basics of async/await, its syntax, and how i...

   JAVASCRIPT,COMPARISON,PROMISE,ASYNC AWAIT     2023-02-12 07:26:15

  What do programmers like to say usually?

Coding is an very important part of programmer's daily work. But beyond coding, programmers need to do other work as well, they need to fix bugs reported by users, they need to write documents for their codes. Also, they often need to answer questions from customers, bosses and colleagues. What do they often say when they are facing different sort of questions? Today we share some. It's done. I just need to clean up a few things. This is hacky, but I'll fix it soon. This can never happen: It's ...

   Programmer,Execuse,Bug     2013-08-07 07:38:30

  Error handling in GoLang

Error handling is one of the must talked topics for any programming language. The program would be more reliable and stable if errors are handled properly and timely. Each programming language has its own way to handle error, this applies to GoLang as well. This post will discuss more about GoLang's error handling mechanism. Error handling Before talking more about GoLang's error handling, we can see how different programming languages are handling errors. C's error check The most direct way of ...

   GOLANG,ERROR HANDLING,FLUENT INTERFACE     2021-03-06 21:36:08