AudioClip Move Constructor Steals the Samples
easyQuestion 736AudioClip is written for you except its move constructor. m_samples is a simple pointer to ONE heap array of ints. Write AudioClip(AudioClip&& other) noexcept so the new clip takes over the other clip's array and count, and the other clip is left with nullptr and a count of 0 (so its destructor frees nothing and it reports zero samples). Moving copies one pointer; no sample is copied.
The hidden driver reads n then n sample values into a clip, move-constructs a second clip from it with std::move, and prints the second clip's size, first and last sample on one line, then the source clip's size on the next.
For the input:
3
7 8 9the exact output is what is shown in Expected Output.
Free the memory you allocate — this question checks for memory leaks.
Do NOT write a main function.
Expected output
moved: 3 samples, first 7, last 9 source: 0 samples
= newline. The output ends with a newline, so print one after the last line.
Your output
Run your code to see the output here...