Company: UKG OnCampus_14june

Difficulty: medium

Problem Statement

You are working on a specialized expression evaluation system that processes mathematical expressions using two different container strategies simultaneously. The system receives a sequence of operations that can be either arithmetic operators (+, -, *, /) or container manipulations (PUSH, POP, ENQUEUE, DEQUEUE ). The system maintains two separate containers: one follows Last-In-First-Out (LIFO) principle and another follows First-In-First-Out (FIFO) principle. When processing arithmetic operations, the system retrieves operands from both containers and performs the calculation. The result is then stored back into both containers. Your task is to simulate this dual-container system and return the final state of both containers along with all intermediate calculation results. Function Description: You need to implement the function processDualContainerOperations . The function processes a sequence of commands that manipulate two containers and performs arithmetic operations using operan

More UKG OnCampus_14june OA questionsInterview experiences