How can you quickly find the number of elements stored in a
a) static array b) dynamic array ?
Answer Posted / brainless
b) use pointer of last element - pointer of first element + 1
However, we should know the last element's pointer...
Is This Answer Correct ? | 0 Yes | 2 No |
Post New Answer View All Answers
Is java based off c++?
What are the advantages of inheritance in c++?
How do you establish an is-a relationship?
What are the advantages of c++? Explain
What is the purpose of the "delete" operator?
What do you mean by function pointer?
Difference between inline functions and macros?
Which is better turbo c++ or dev c++?
What are the comments in c++?
Can member functions be private?
Does a derived class inherit or doesn't inherit?
Explain rtti.
Is oops and c++ same?
How is c++ used in the real world?
What are c++ files?