Company: flipkart-grid-8.0_19thjuly_2
Difficulty: medium
Second Highest January Salary Read this first - this is a programming question, not a SQL question. The data is described in database terms below because that is how the original assessment posed it, but no database is involved. The tables are handed to your program on standard input as pipe-delimited text (see Input Format ), and you print the answer on standard output . Solve it in Python, C++ or Java by completing the solve function in the starter code. solve receives the four tables as lists of string fields and returns the output lines. A SQL query submitted here will not run. Description A company keeps its payroll in five tables: dept , emp , designation , compensation and emp_dept . The employer wants to know the second-highest salary paid to an employee in the month of January 2021 , together with the people who received it and the departments they work in today. The Tables The column types below describe the shape of each field; they are documentation only, and the values rea