Blog

Page 734 of my articles, tutorials, and thoughts

Latest Articles

Cover Image for Difference between "struct" and "typedef struct" in C++?

Difference between "struct" and "typedef struct" in C++?

Published on September 2, 2023

# Understanding the Difference between 'struct' and 'typedef struct' in C++ ๐Ÿค” Are you a C++ developer who has ever wondered about the difference between `struct` and `typedef struct`? If so, you're not alone! Many programmers have found themselves ponder

Cover Image for Concatenating two std::vectors
concatenationvector

Concatenating two std::vectors

Published on September 2, 2023

๐Ÿ“๐Ÿ”ฅ **Tech Tidbits: A Guide to Concatenating `std::vectors`** ๐Ÿ”๐Ÿ’ก Ever found yourself in a conundrum of merging two `std::vectors` and wondering how to tackle it? Concatenating two `std::vectors` might sound like a daunting task, but worry not! In this

Cover Image for What is the strict aliasing rule?
c#

What is the strict aliasing rule?

Published on September 2, 2023

๐Ÿ“Lingo Decoder: Understanding the Strict Aliasing Rule in C ๐Ÿค”๐Ÿ’ญ Have you ever stumbled upon a coding discussion where people start throwing around terms like "strict aliasing rule" and wondered what on earth they were talking about? ๐Ÿค” Don't worry, you'

Cover Image for Why should C++ programmers minimize use of "new"?
memory-management

Why should C++ programmers minimize use of "new"?

Published on September 2, 2023

# Why should C++ programmers minimize use of 'new'? ๐Ÿ’ป๐Ÿ”€๐Ÿ˜ฑ So, you stumbled upon this Stack Overflow question about a memory leak with `std::string` when using `std::list<std::string>`. In the comments, someone mentioned that you should "stop using `new`"

Cover Image for How to convert an instance of std::string to lower case
string

How to convert an instance of std::string to lower case

Published on September 2, 2023

# Converting std::string to Lowercase: A Foolproof Guide โœจ๐Ÿ”  Have you ever needed to convert a `std::string` to lowercase but found yourself struggling with the `tolower()` function? ๐Ÿ˜ฉ Well, fret no more! In this guide, we will explore a foolproof soluti

Cover Image for How to trim an std::string?
trim

How to trim an std::string?

Published on September 2, 2023

# How to Trim an `std::string`? ๐Ÿ’ก **Are you tired of dealing with pesky whitespace in your `std::string`?** ๐Ÿ˜ฉ Whether you're a seasoned programmer or just starting out, trimming a string can be a common task. In this guide, we'll explore the best practi

Cover Image for What are the new features in C++17?

What are the new features in C++17?

Published on September 2, 2023

๐ŸŽ‰ Introducing C++17: Unveiling the Coolest Features! ๐Ÿš€ Hey there, tech fanatics! Get ready to level up your C++ game because C++17 has some awesome new features in store for you. ๐Ÿคฉ In this blog post, we'll dive into the latest additions to the language

Cover Image for What are the rules about using an underscore in a C++ identifier?
naming-conventions

What are the rules about using an underscore in a C++ identifier?

Published on September 2, 2023

๐Ÿ‘‹ Hey there, fellow tech enthusiasts! ๐Ÿ‘ฉโ€๐Ÿ’ป๐Ÿ‘จโ€๐Ÿ’ป In today's blog post, we're going to address an interesting and commonly asked question in the C++ programming language: what are the rules about using an underscore in a C++ identifier? ๐Ÿ˜ƒ๐Ÿ’ป ๐Ÿค” So, let'

Cover Image for What does T&& (double ampersand) mean in C++11?

What does T&& (double ampersand) mean in C++11?

Published on September 2, 2023

# What Does T&& (Double Ampersand) Mean in C++11? ๐Ÿค”๐Ÿ” So, you're diving into the amazing world of C++11 and stumbled upon something that caught your eye - the double ampersand in variable declarations: `T&& var`. ๐Ÿ˜ฎ You might be wondering, what on earth

Blog | Matheus Mello