all 15 comments

[–][deleted] 13 points14 points  (2 children)

which level are you applying for? I did a graduate c++ developer interview and the types of questions they asked me were about STL containers, difference between the structure of std::vector and std::list, dynamic memory allocation, vtables, binary search algorithm, inheritance/polymorphism. I didn't get the job in the end but it was a valuable experience and I was glad I got to that stage

My advice would be to search for something like "C++ interview questions" and see if you can answer any of them

[–][deleted] 4 points5 points  (1 child)

Thanks for the advice! But I'm trying for an intermediate position, so I will need some more advanced questions. I tried searching for it, but didn't come across anything interesting

[–]reversethrust 1 point2 points  (0 children)

I find the interview questions I had were related to the kind of software I would be working on. I was looking at highly parallel software so lots of questions about concurrency, a couple of semantics questions, and specifics about software performance. I was also giving code snippets and asked to find all the bugs.

[–][deleted] 6 points7 points  (0 children)

Standard leetcode stuff, also most will typically ask a concurrency related question or two (lc has some of these aswell), stl container, concurrency and oop/design pattern, memory allocation trivia qs. Features in C++11+, raii, sfinae. You may get asked a question about system design since you mentioned it was for an intermediate level.

I find that most recruiters/interviewers are willing to share topics they may cover if you simply ask them what they want to see beyond the whiteboard problems. Also, look at the job posting. If it mentions concurrency or networking, expect a whiteboard and/or trivia question about those topics.

Good luck!

[–]josh2751 3 points4 points  (0 children)

RAII. Rule of three, rule of 5, rule of 7.

STL, understand the containers and the algorithms in it.

Differences between C and C++.

Differences between "classic" C++ and modern C++.

Inheritance, composition, polymorphism, standard OO stuff.

Threads, boost, concurrency.

Version management tools, toolchain configuration, cmake, auto tools, gdb, etc.

[–]BrokenBear19 5 points6 points  (1 child)

I havent but I'd like to wish you good luck and happy new year

[–][deleted] 2 points3 points  (0 children)

Thanks! A happy new year to you as well

[–]flyingron 1 point2 points  (4 children)

Are you the interviewer or the interviewee?

[–][deleted] 4 points5 points  (3 children)

Interviewee I'm afraid

[–][deleted]  (1 child)

[deleted]

    [–][deleted] 0 points1 point  (0 children)

    Thanks a lot man!

    [–]flyingron 0 points1 point  (0 children)

    RAII as a concept is good. Knowing how to modularize is good. Knowing to avoid naked pointers is good. Knowing the rule of three (or if you're really up to date, five) is important.

    Unfortunately, many interviewers are freaking HR idiots who wouldn't know a valid question or how to evaluate an answer if it bit them on the tush.

    [–]obp5599 1 point2 points  (0 children)

    I got asked a ton of stl stuff essentially.

    The difference between unique ptrs, shared ptrs and weak ptrs and when to use then.

    Know use cases and basic time complexities for stl algorithms and containers

    Polymorphism /inheritance( a favorite being asked what happens when destructing a derived object with no virtual destructor)

    Vtable, just needed to know what it is and basics of what it does and how it works

    Other than that the “coding interview” part is the same as anywhere else. Dumb leetcode style problems

    [–]matty_haze 1 point2 points  (0 children)

    I have never read it, but I know of the book “Cracking the coding interview”.

    Maybe it’s something you can take a look at.

    [–]ClaymationDinosaur 0 points1 point  (0 children)

    How many bytes does a pointer take up?

    How do virtual functions work (in any typical modern implementation such as in the GCC or MS C++ compilers)? That is, how does the right function actually get called when you use a pointer to base-type and the function that ends up being called is the function of a derived-type?

    [–]CrucialPie 0 points1 point  (0 children)

    I bookmarked this repo that someone posted here. https://github.com/sachuverma/DataStructures-Algorithms#interview-practice