© 2023 Hashnode
#cpp
Today I Solved the following problems on CodeChef: https://www.codechef.com/problems/NEGPROD https://www.codechef.com/problems/POLTHIEF https://www.codechef.com/problems/JENGA https://www.codech…
the lambda expression was first introduced to the programming world after the function pointer as we discussed previously. the function pointer refers to a pointer that holds the address of the function to be used as an argument to another …
Hii Developers, From the beginning I was very confuse about printf() vs cout printf() - it is a function, we can pass data and this function will print it on console cout - It is object not a function, but if it is object then why we do not…
A Hands-on Approach to Understanding and Implementing the Factory Design Pattern in a Real-World Application First of all, let's define the Requirements of our problem There can be multiple banks Al…
What are pointers? The pointer variable points to a data type of the same type(like int, char etc. ). The address of the variable we are working with is assigned to the pointer. In other words, a poin…
Problem statement Given a 2D grid of size m x n and an integer k. You need to shift the grid k times. In one shift operation: Element at grid[i][j] moves to grid[i][j + 1]. Element at grid[i][n - 1]…
Basics of OOPs Welcome to the first post in our C++ OOPs tutorial series! In this post, we will be discussing the concepts of classes and objects in C++. If you are already familiar with the basics of C language, you will find that classes …
C++ is a popular programming language known for its powerful features and versatility. It is widely used in various applications such as game development and scientific computing. In this blog post, w…
Today I Solved the following problems on CodeChef: https://www.codechef.com/problems/TRUESCOREhttps://www.codechef.com/problems/DISCUShttps://www.codechef.com/problems/FINDSHOEShttps://www.codechef.co…
Problem statement An n-bit gray code sequence is a sequence of 2^n integers where: Every integer is in the inclusive range [0, 2^n - 1], The first integer is 0, An integer appears no more than once in the sequence, The binary representa…