를 링크하여전화 번호부 더블 목록을
list *newList = new list;
int choice = 0;
while (choice != 3)
{
printf("What would you like to do?\n");
printf("1 - Insert something in the phonebook?\n");
printf("2 - Search something from the phonebook?\n");
printf("3 - Nothing at all\n");
printf("Enter 1 through 5: ");
scanf_s("%d", &choice);
switch (choice) {
case 1:
newList->addNode();
break;
case 2:
newList->searchNode();
break;
default:
printf("\nThank you for using the phonebook\n");
}
choice = 0;
}