C++ Interview Questions in Kolkata
36 practice questions with answers for C++ interviews in Kolkata.
C++ jobs in Kolkata
Kolkata has a steady IT-services and BFSI technology job market around Salt Lake Sector V and New Town. Many openings are with service companies and their delivery centres, with a focus on strong fundamentals.
Below are 36 questions that match the mix of service, product and domain employers hiring junior c++ developers in Kolkata.
What are templates in C++? Explain function and class templates.
Show answer
What is the difference between const int*, int* const and const int* const?
Show answer
What is the difference between const and constexpr?
Show answer
What do compiler optimisation levels like -O0, -O2, -O3 and -Os mean?
Show answer
What is object slicing?
Show answer
How do you create a thread in C++ and what is the difference between join and detach?
Show answer
You need a container that holds ints, strings and doubles together. Which approach would you choose?
Show answer
How do you handle a tight deadline when the C++ code you need to change is complex?
Show answer
Write a swap function using references and explain why a pass-by-value version fails.
Show answer
Explain the rule of three, rule of five and rule of zero.
Show answer
Write a generic function template that returns the larger of two values.
Show answer
What are lvalues and rvalues?
Show answer
You call a virtual function from a base class constructor but the derived override never runs. Why?
Show answer
What is the difference between an inline function and a macro?
Show answer
Write a C++20 concept and use it to constrain a function.
Show answer
Why are templates usually defined in header files?
Show answer
A binary runs on your laptop but fails on the server with error while loading shared libraries. What is wrong?
Show answer
How do virtual functions work internally?
Show answer
Tell me about a time you found a difficult bug in your C++ code.
Show answer
What are AddressSanitizer, UndefinedBehaviorSanitizer and ThreadSanitizer?
Show answer
What is a void pointer and when would you use it?
Show answer
Use std::variant and std::visit to handle different message types.
Show answer
Design a class structure for UPI, card and net banking payments in a checkout system.
Show answer
A function taking a Money object is silently called with an int and gives wrong results. What is happening?
Show answer
A full build of your C++ project takes 40 minutes. How would you reduce it?
Show answer
A program crashes with terminate called without an active exception when a function returns. What is the cause?
Show answer
Code that erases elements from a vector inside a range-based for loop crashes. Why, and what is the correct way?
Show answer
How do you prioritise when a critical bug and a feature deadline arrive at the same time?
Show answer
Implement a minimal unique_ptr-like class.
Show answer
What is a deadlock and how do you prevent it?
Show answer
Which profiling tools do you use for C++ and what does each show?
Show answer
What is template argument deduction and class template argument deduction?
Show answer
Why should we hire you for this C++ developer role?
Show answer
When would you use std::set versus std::priority_queue?
Show answer
Explain the stages of compiling and running a C++ program.
Show answer
Frequently asked questions
Which companies hire C++ professionals in Kolkata?
Companies with large offices in Kolkata include many IT services and product firms. Use their company pages below to practise employer-specific sets.
Are C++ interviews in Kolkata different from other cities?
The questions depend more on the company than the city. Kolkata's mix of employers decides the style: Many openings are with service companies and their delivery centres, with a focus on strong fundamentals
How do I find C++ jobs in Kolkata?
Shortlist companies with Kolkata offices, keep your CV focused on C++ projects, apply on company career pages and job portals with the Kolkata filter, and practise the questions on this page before each interview.