From 543d6e01353d01f2499a795c750502a00d7f92af Mon Sep 17 00:00:00 2001 From: Tanisha Belkar <68585820+tanishabelkar@users.noreply.github.com> Date: Wed, 2 Feb 2022 11:04:52 +0530 Subject: [PATCH] chore: add exit as an option in the... (#1931) ...Linked List file algorithm. * Bug: Added exit condition to the linked list menu * revert back * fix: added exit condition to the linked list display menu * update Co-authored-by: David Leal --- data_structures/linked_list.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/data_structures/linked_list.cpp b/data_structures/linked_list.cpp index eafc5f026..08bfe68b1 100644 --- a/data_structures/linked_list.cpp +++ b/data_structures/linked_list.cpp @@ -233,6 +233,9 @@ int main() { std::cout << "\n\nEnter you choice : "; std::cin >> choice; switch (choice) { + case 0: + std::cout << "\nQuitting the program...\n"; + break; case 1: std::cout << "\nEnter the element to be inserted : "; std::cin >> s;