Concatenates the single character ch onto the end of string


A character string can be implemented as a linked list of characters. Create an ADT in C++ called Newstring that uses linked lists to implement the following string operations:

concatenate(Newstring addString)

copies contents of parameter onto the end of string; does not merely make end of string point to beginning of Newstring object

concatenate(char ch)

concatenates the single character ch onto the end of string

display()

display string on standard output

length()

returns the length of string

In all cases string refers to the private data of your ADT. In implementing this ADT, you may want to write additional, private methods to assist the others. Write a short program to test your ADT.

Request for Solution File

Ask an Expert for Answer!!
Basic Computer Science: Concatenates the single character ch onto the end of string
Reference No:- TGS0136255

Expected delivery within 24 Hours