Get Off-Campus Placement Jobs Info !!!
Programs asked in Mettl Coding Round
Click To Practce List of Programs asked in Nagarro !!!

OLA Interview Questions


Total Set :1

Top 10 OLA Interview Questions With Answer

Question: 1 / 10

What is pragma, The questions was if multiple .h is included, how you can handle it

Question: 2 / 10

How can we use one .h file on different dll

Question: 3 / 10

What are the compiler steps, In details.

Question: 4 / 10

What design pattern you used on FOTA

Question: 5 / 10

How dynamic linking and static linking happen on compiler, exception was in detail.

Question: 6 / 10

Design trace class and How do you include on different dll

Question: 7 / 10

How to handle when destract is failing.

Question: 8 / 10

How compiler handle perfix and postfix, operator overloading. which is better to use

Question: 9 / 10

What is different between resize and reserved.


--> correct question i.e What is difference between resize() and reserve()?

The resize() method (and passing argument to constructor is equivalent to that) will insert or delete appropriate number of elements to the vector to make it given size (it has optional second argument to specify their value). It will affect the size(), iteration will go over all those elements, push_back will insert after them and you can directly access them using the operator[].

The reserve() method only allocates memory, but leaves it uninitialized. It only affects capacity(), but size() will be unchanged. There is no value for the objects, because nothing is added to the vector. If you then insert the elements, no reallocation will happen, because it was done in advance, but that's the only effect.

Question: 10 / 10

What is smart pointer, and its use.