COSC 2007: Data Structure II
Assignment#2
Exercise1
Write the details algorithm to convert from infix expression to postfix expression and evaluate
the value of prefix expression using recursion. Convert the algorithm into Java code.
Exercise2
Write the details algorithm and convert it into Java code for the solution of the following
problem
In this assignment, you are given the following dictionary as a reference. You may create your
own data for dictionary input. You implement the dictionary/table as an ADT by the following
methods.
1- Array-based implementation
2- Reference based implementation
You implement the following DICTIONARY/TABLE ADT operations
a) Insert a new item into a table
b) Delete the item with a given search key from a table
c) Retrieve the item with a given search key from a table
Methods/Functions: You can design insert( ), delete( ), and retrieve( ) methods to describe a
dictionary/table as an ADT.
Outputs: You should display the output for all methods.
What to submit: The submissions are Exercise1 and Exercise2.
How to submit an Assignment: You can prepare a document either text file or pdf file. Course
name, Student name, and student number should be written at the top of a report. You can submit
assignment through Assignment#2 from your Moodle account. You have to submit java source
files too.
Submission Due: The submission due is February 23, 2025.
Submission Files:
-Report
-Java source files
Submission Report Format:
Assignment1
<Course Name>
<Student Name>
<Student Number>
Exercise No
<Type the question here>
Algorithm/ Pseudocode
Code
Output
Conclusion
Note: Late submission or without Java source files, the grade will be 0.