Implement Stack and Queue data structures using a linked list and array

SuperClass
 (Not rated)
 (Not rated)
Chat

Page -1 -of 3 CCaallccuullaattoorr pprrooggrraamm OObbjjeeccttiivveess ? Learn more about Stacks and their application ? Learn more about infix and postfix expressions ? Implement Stack and Queue data structures using a linked list and array. TThhee pprroobblleemm An infix expression is one in which operators are located between their operands. This is how we are accustomed to writing expressions in standard mathematical notation. In postfix notation, the operator immediately follows its operands. Examples of infix expressions are: Infix Postfix a * b a b * f * g – b f g * b – d /e * c + 2 d e /c * 2 + d /e * (c + 2) d e /c 2 + * One advantage of postfix is that unlike infix, no parentheses are necessary. Another advantage is that postfix expressions are easily evaluated using a stack. This project will require you to create a Java program that will take an input file consisting of several lines of infix notation mathematical calculations, convert them to postfix notation (using the first algorithm in Part1), and evaluate them (using the second algorithm in Part2). The results of the calculations will then be printed to an output file. This project will build on your array and linked list implementations, using them to create your own implementations of stacks and queues for each of the algorithms. TThhee mmaaiinn ppaarrttss ooff tthhee ccaallccuullaattoorr pprrooggrraamm aarree:: PPaarrtt 11:: Infix to Postfix conversion This part will use both a stack and queue in order to convert expressions from infix to postfix notation. The stack and queue will be implemented by you, using your linked list implementation from labs. For this part, you will need to maintain two queues and one stack: ? A stack for conversion Infix to Postfix (Using Array Implementation) ? A queue for accumulation the digits of the operand (NumQueue) (Using Array Implementation) ? A queue to store the Postfix notation (PostQueue) (Using Linked list Implementation) Each value will be read from the...

  • 10 years ago
Implement Stack and Queue data structures using a linked list and array A+ tutorial use as guide
NOT RATED

Purchase the answer to view it

  • implement_stack_and_queue_data_structures_using_a_linked_list_and_array.docx
  • implement_stack_and_queue_data_structures_using_a_linked_list_and_array_1.txt
  • implement_stack_and_queue_data_structures_using_a_linked_list_and_array_2.txt
  • implement_stack_and_queue_data_structures_using_a_linked_list_and_array_3.txt
  • implement_stack_and_queue_data_structures_using_a_linked_list_and_array_4.txt
  • implement_stack_and_queue_data_structures_using_a_linked_list_and_array_5.txt
  • implement_stack_and_queue_data_structures_using_a_linked_list_and_array_6.txt