30 Seconds of C++

Bhupesh Varshney 👾 - May 5 '19 - - Dev Community

So if you are looking forward to learn C++ in 2019, I present to you the 30 Seconds of C++.

A collection of STL (Standard Template Library) features of C++ which can be learned in 30 seconds or less.

What is it again? 🧐

30 Seconds of C++ (hereafter referred to as 30C++) is a collection of modern C++ STL features like algorithms, containers, etc combined into short C++ snippets that can be learned in 30 seconds or less.
Inspired by the 30 Seconds of Code

Why did you make it? 😮

I personally find it hard to learn modern C++ (C++ 14,17) through numerous C++ tutorials which either have incomplete info or if you wanna go further you may find yourself browsing these websites for modern C++

The problem with the above 2 resources is that they sometimes give too much info overshadowing the simple things to understand and from a perspective of a "beginner" who has just started learning that can be frustrating.
Although both these resources are damn good if you have a basic understanding which 30C++ can give.

Why would I learn C++? 😒


No doubt languages like JavaScript, Python, Java are ruling the programming world currently but the undoubted presence of C++ in the top 10 languages prove that C++ is evergreen and its presence will never diminish.
Check out these blogs for detailed comparisons :

TIOBE Index C++

Although to not break your bubble C++ takes a ton of time to master & feel its true essence. (figuring out myself)

I myself use Python as my main language but over the years C++ has helped me become a better developer, even if you are new to programming, using C++ as your starter language will be a good choice.

Even if you're not learning C++ from Job point of view, it offers a ton of learning experience.
See 5 Reasons Why You Should Keep Learning C/C++

More Resources


Here are some of the resources (blogs) which I currently follow :

PS: avoid these if you are very new to C++

How will it help me? 🤔

  • 30C++ includes all the modern C++ features & more of them are coming day by day.
  • It can help you learn modern C++ step by step without browsing through any lousy and confusing documentation.
  • Currently, some of the library headers available are :

    • <algorithm>
    • <list>
    • <stack>
    • <queue>
    • <vector>
  • Also learning modern C++ will surely help if you are seeking a professional career in C++.

  • If you are a CS Student then learning C++ will be surely helpful, Why CS students must learn C++ as their main programming language

  • All the Snippets are explained in an easy to understand lucid manner with a link to run the example code.


  • As quoted by Bartlomiej Filipek

    I am not saying that C++ is fantastic and you should abandon everything and just stick to it. If you’re just starting it’s good to have more options and learn different things. Even if you’re a C++ guy already, it’s vital to learn something new and improve.

30 Seconds of Knowledge 👨🏽‍💻

If you are lazy(like me) you can also learn C++ and experience 30C++ on your browser by adding this awesome web extension to your favorite browser built by Stefan Petrovic.
Know more about 30 Seconds of Knowledge

Weekly Series Announcement

teach_you

So with the help of 30C++, we will be learning together modern C++ through a series of C++ blogs that I will be posting starting soon.

Contribute 😋

If you would like to contribute check out some of the open issues :

Add new methods in different header directories #31

This is for first-time-contributors : Add functions which belong to a particular header file in its corresponding .md file inside the header folder. For example std::sort belongs to algorithm header file, so make a new file sort.md inside the algorithm directory while maintaining the CONTIBUTING guidelines and formats.

See todo.txt file in different header directory to see which of the methods have not been implemented yet.


Add Run Code Links in existing code snippets #36

Add Runnable links of the code below the example. Use link name Run Code which links to a Online C++ complier conatining the example code. Use Rextester as the Online C++ Compiler (If you have a better suggesstion please comment).

Follow below steps to generate the Run Code Link.

  1. Go to Rextester
  2. Copy or write the example code.
  3. Run the code (hit F8) , see if you face any problems
  4. Save the code with the followng title format <algo_name>_30-Seconds-of-C++
  5. A permanent link will be generated , copy that
  6. Submit a PR which contains the Run Code Link just below the example.

Comment any doubts, suggesstions.


develop weekly newsletter #38

Develop a weekly newsletter for sending random code snippets to subscribers.

https://app.leanboard.io/board/a7721e60-20e7-4352-b365-8bc725ed7c2a

Feedback 🤗

If you like to suggest anything please open an issue or comment below.

Also don't forget to Checkout my website for more blogs.

Logo & Cover Image by: Shriam Kaushik

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Terabox Video Player