Data Structure Test 4
a. Roll Number of student
b. Name of student
Write add(List) and pop(List) methods in python to add and remove from the stack.
Ans.
Q2. Write push(edetail) and pop(edetail) in python to add and remove the employee detail in a stack called "edetail".
"edetail" stack store the following details:
a. Name of employee
b. Salary of employee
Ans.
Q3. Write addscore(game) and delscore(game) methods in python to add and remove score from a list "game", considering these methods to act as push and pop operations of data structure stack.
Ans.
Q4. Write addsal(sal) and removesal(sal) functions in python to add and remove salary from a list of salary in a list "sal", considering these methods to act as push and pop operations of data structure stack.
Ans.