Given an array of characters of specified size, store a string into the array and display in loop the output after executing the command deletion(s) and addition(s).
Sample Run:
Enter String: ILoveBacolod
Enter a command: Delete (D)
Output: LoveBacolod
Enter a command: Delete (D)
Output: oveBacolod
Enter a command: Add (A)
Enter a character: z
Output: oveBacolodz
Can you please give me a code that is similar to this. I'll just modify it. Thanks. :)
Afaik queues can not be read like that, they're merely container adapters making a FIFO structure. But your task asks about an array, the tutorial on this site may help you. http://www.cplusplus.com/doc/tutorial/arrays/