How do you clear a buffer in c++?



How do you clear a buffer in c++?..

Answer / Rizwan Ali

To clear a buffer in C++, you can use the 'std::fill' function to fill it with a specific value or 'std::memset' if dealing with raw memory.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C++ General Interview Questions

Explain the properties and principles of oop.

1 Answers  


What is ios class in c++?

1 Answers  


What are its advantages and disadvantages of multiple inheritances (virtual inheritance)?

1 Answers  


Is map ordered c++?

1 Answers  


What are the rules for naming an identifier?

1 Answers  


Is it possible for the objects to read and write themselves?

1 Answers  


What are the advantages of pointers?

1 Answers  


Draw a flow chart and write a program for the difference between the sum of elements with odd and even numbers. Two dimensional array.

1 Answers  


How do you initialize a string in c++?

1 Answers  


Why is polymorphism useful?

1 Answers  


Please explain the reference variable in c++?

1 Answers  


Difference between a homogeneous and a heterogeneous container

1 Answers  


Categories