Articles

Networking in UNIX systems - Back to basics track - Part-1 (Socket address structure, IPv4, IPv6) πŸ‘‹

In this article, we explore the basic networking concepts in UNIX based operating systems. We start with sockets, IPv4, IPv6.

Posted July 25, 2021 by FluentProgrammer ‐ 5 min read

Enumerations and Class Enumerations in C++ πŸ‘‹

Enumerations are always fun to use in C++ programs. C++ core guidelines define eight different rules to define the enumerations. And also, C++11 introduced the scoped enumerations also called as class enumerations. Scoped enums also have few advantages over plain enums which are also covered in this article.

Posted July 5, 2021 by FluentProgrammer ‐ 5 min read

A Taxonomy of Expression Value Categories in C++πŸ‘‹

C++ had value categories in C++0X version. The two value categories that were before C++11 are lvalues and rvalues. One of the greatest addition to C++11 was the introduction of movable types. Learning about the value categories is one of the pre-requisites to learn about move semantics. Any expression before the C++11 standard was either lvalue or rvalue. lvalue has an identity and its lifetime depends on the scope of the variable. On the other hand, rvalues don't have an identity and it does not live beyond the life of the expression.

Posted May 14, 2021 by FluentProgrammer ‐ 5 min read

Using Templates for Generic Programming - Part 1 (Embracing the beauty of SFINAE and enable_if)πŸ‘‹

In this blog post, we will learn advanced template programming concepts. These concepts include how to change the implementation of classes and functions based on the type provided, how to work with different arguments and how to properly forward them, how to optimize the code in both runtime and compile-time, about SFINAE, std::enable_if, std::enable_if_t.

Posted April 27, 2021 by FluentProgrammer ‐ 9 min read

Function Templates in C++ πŸ‘‹

Overloaded functions have the exact same code but the type is different. It seems an unnecessary overhead to write the same code again and again and in a long time it adds up to the maintenance cost of the project. To write code once and use it multiple times we use function templates. A function template is itself is not a definition of a function; it is a blueprint for defining a family of functions.

Posted April 22, 2021 by FluentProgrammer ‐ 14 min read

C++ Best Practice #1: Don't simply use: using namespace std; πŸ‘‹

Never try to import the whole std namespace into your program. Namespaces are developed to avoid naming conflicts. But, when we import the whole namespace there is a possibility that this could lead to name conflicts. You can do more harm than more good.

Posted April 21, 2021 by FluentProgrammer ‐ 2 min read

Volatile Keyword in C and C++ πŸ‘‹

Quoting from the C++ Standard ($7.1.5.1/8) [..] volatile is a hint to the implementation to avoid aggressive optimization involving the object because the value of the object might be changed by means undetectable by an implementation.[…]

Posted April 21, 2021 by FluentProgrammer ‐ 2 min read

βœ‚οΈ Copy and πŸ“‹ Paste Emoji πŸ‘ πŸ‘‹

Emojis are supported on iOS, Android, macOS, Windows, Linux and ChromeOS. Copy and paste emojis for Twitter, Facebook, Slack, Instagram, Snapchat, Slack, GitHub, Instagram, WhatsApp and more. Use Emoji Classic on older systems.

Posted April 19, 2021 by FluentProgrammer ‐ 16 min read