Should I consider memmove() O(n) or O(1) ?
Posted
by Andrei Ciobanu
on Stack Overflow
See other posts from Stack Overflow
or by Andrei Ciobanu
Published on 2010-04-25T21:16:57Z
Indexed on
2010/04/25
21:23 UTC
Read the original article
Hit count: 225
Hello, this may be a silly question, but I want to calculate the complexity of one of my algorithms, and I am not sure what complexity to consider for the memmove() function.
Can you please help / explain ?
void * memmove ( void * destination, const void * source, size_t num );
So is the complexity O(num) or O(1). I suppose it's O(num), but I am not sure as I lack for now the understanding of what's going on under the hood.
© Stack Overflow or respective owner