Can you please help me write an in-place function in C++ for reversing
What is an in-place function?
So what is a non-in-place function in that case to reverse a C++
Urgent help needed.
Re: In-place function
> What is an in-place function?
Function that works without additional memory allocation.
In fact, constant additional memory may be allocated, but the amount of
additional memory should not be depended with the input.
Non-in-place is just the opposite...
The question sounds like homework, so the general idea will be to
implement a "swap" function (with a temporary variable), only that the
two arguments to swap are pointers to the start/end of the string.
|All times are GMT. The time now is 08:01 AM.|
Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.