givemeananswer
classProgram
{
staticvoidMain(string[]args)
{
LinkedListlist=newLinkedList();
list.AddFirst(10);
list.AddLast(20);
list.AddLast(30);
list.AddLast(40);
Theaboveprogramisincomplete,pleasecompletetheaboveprogramtoperformfollowingoperationsonlinkedlist,theoperationstobeperformedare:
i.Displaytotalnumberofnodesintothelinkedlist
ii.Addvalue:25after20.
iii.Addvalue5before10
iv.Checkthatthelistcontainsvalue30,ifcontainsdisplayamessage“30isintothelinkedlist”
v.Displaythevaluesofallthenodesfromthelinkedlist.