Question: heres the question from task 2 task 5 java lang Ow WO6 AutoSave) woo Lab ArrayLists and Trees - Word Search Wdra del spsc.instructure.com Home



heres the question from task 2
task 5 java lang
Ow WO6 AutoSave) woo Lab ArrayLists and Trees - Word Search Wdra del spsc.instructure.com Home Insert Design Rulerences Mailings Review HO Table Design e Black Lake Find - X 09 POF Curre... AaRbce Aalb De Alice Alban Conclu.. La Figu. Lab Figuel Gual Lab Goal. Replace Peale Calin (Body - 11 - A A A A A A21 11 BIU XX AVAA Font Paragraph Dista Su Susitivity Editor = CS 143-4714 > Fi Clipboard Styles F Editing Woice Sensitivity Editor W 2023 Task 2. Trees (5 points, about 0.25 points per question) Thanks to Allu & Ul. Foundations of Computer Science, Eric 5.21. Ole Account Home Announcements Dashboard (2 3 Grades Courses Discussions Syllabus 1 5 7 Calendar Library (10 (11 12 Ask The Librarian de Inbox (13 (14) Virtual Tutoring lololo Office 365 History Bookstore Canvas into College Syllabus Resources 15 - For this tree, what is described by each of the following phrases? a) The root of the tree: Nede b) The leaves of the tree: Nodes The interior nades of the tree: Nades , and Student Events d) The siblings of nade f: Nordes The subtree with root S: Nodes f] The ancestors of node 10: Nodes el The descendants of node 10: Nades h) Siblings to the left of node 10: Nodes 0 Siblings to the right of node 10: Nodes J) The longest path in the tree: Nodes k! The depth of nade 3: 0 The depth of node 13 ml The height of the tree: Type here to search TI 2 ING 5:11 PM 2/14/2021 Ow WO6 AutoSave) 0 - woo Lab ArrayLists and Trees - Word Search Wdra del spsc.instructure.com Home Insert Design Rulerences Mailings Table Design Layout e Black Lake X 09 Find - Replace POF Curre... AaRbce Aalb De Alice Alban Come... Lab Figu.. Tab Figu. Lab Goal 1Lab Goal.. Peale Calin (Body - 11 - AAA AAA 211 BIUXX AVAA Font Paragrph Dista Sunty = CS 143-4714 > Fi Clipboard Styles Eding Woice Sensitivity Editor W 2023 Ole Account Home Announcements Dashboard Grades Rubric: Student name and today's date is a comment in the first line of the programs: -10 points if fails Screenshot and program code: 10 points if fails All lines of proeram output shown: -10 if fails Tree creation for two additional trees: 4 points - Pre-order traversal and output for all three trees: 3 points Past order traversal and output for all three trees: 3 points Courses Discussions Syllabus Calendar Library Please paste a screenshot of a successful program run with all lines of output, and copy and paste the source code from your main program's java file here. You do not need to include the TreeNode.java file. Ask The Librarian de Inbox Virtual Tutoring Office 365 History Bookstore Canvas into College Syllabus Resources Student Events Type here to search o it TE ING 5:11 PM 2/14/2021 Ow WO6 AutoSave) woo Lab ArrayLists and Trees - Word Search Wdra del spsc.instructure.com Home Insert Design Rulerences Mailings Review Table Design Layout e Black Lake Find - X 09 POF Curre... Replace Peale Dista Sunty = CS 143-4714 > Fi Clipboard Editing Woice Sensitivity Editor W 2023 Ole Calin (Body - 11 - A A A A A A 21 11 AaRbce Alben: A han BIUXX A PAA 1 Conc. Lub Fiou.. 1 Lab Fiqh dual Label Font Paragraph Styles Task 5. Pre-order and post-order traversal (10 points) Implement the textbook's algorithm (not the lava implementation for pre-order and post-arder traversal. To "process" or "Visit" a node means to print the data at that node. Algorithm preorder(p): perform the "visit" action for position p { this happens before any recursion) for each childc in children p do preorder c) recursively traverse the subtree rooted at Code Fragment 8.12: Algorithm preorder for performing the preorder traversal of a subtree rooted at position pof a tree Account Home Announcements Dashboard Grades Courses Discussions Syllabus Calendar Library Ask The Librarian de Inbox Virtual Tutoring lololo Algorithm postorder(P) for each child c in children(p) do postorderc) recursively traverse the subtree rooted at perform the visit" action for position this happens alternyrusion Code Fragment 8.13: Algorithm postorder for performing the postorder traversal of a subtree rooted at position pof a tree. Thanks to Goodrich, Algorithms and Data Structures in Java, 6 Edtion Focl free to use the trec and code from Task 2 as a test case. Office 365 History Bookstore Canvas into College Syllabus Resources Student Events The tree from Task 2: Pre-order traversal Output: 10 6 4 8 18 15 21 Pust-order traversel output: 4 8 6 15 21 18 19 Additionally, create and traverse the following trees: Root edu com (2) une yahoo google CS med maps Type here to search O ING 5:11 PM 2/14/2021
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
