2 2 votes true/false ? ) if stack is implemented as a array,all operation push ,pop ,is emptystack(),delete stack() can be performed in constant time. )if stack is implemented as a linked list ,all operation ,is emptystack(),delete stack() can be performed in constant time. Programming in C data-structures queue stack + – Gurdeep Saini 2.4k views answer comment Share Follow Print See all 7 Comments 7 7 Comments reply Show 4 previous comments Gurdeep Saini commented Jan 2, 2019 reply Follow flag ok thank now in the first option you said delete stack() -> I think it can be done by ignore data in the array and override. If this is true then 1st statement is TRUE what about this logic ? after watching the answer 0 0 replyShare Hemanth_13 commented Jan 2, 2019 reply Follow flag This we can manage right... We will have the index till top of the stack so we can restrict ourselves by not going beyond that index for read access. And for write if we go we will overwrite with new value 0 0 replyShare Himanshu Kumar Gupta commented Aug 23, 2020 i edited by Himanshu Kumar Gupta Aug 25, 2020 reply Follow flag 1st is True 2nd is False becuse when we apply Delete Stack in case of linked list we need to delete all the element which take O(n) time if there is “n” element , but in case of array if we want to delete a Stack we just overwrite from begining . 0 0 replyShare Please log in or register to add a comment.
0 0 votes 1st is True 2nd is False because when we apply Delete Stack in case of the linked list we need to delete all the element which take O(n) time if there is “n” element but in case of array we just overwrite from beginning when we want to delete a Stack Correct me if i am wrong Himanshu Kumar Gupta answered Aug 23, 2020 • edited Dec 15, 2023 by Hira Thakur Himanshu Kumar Gupta comment Share Follow 0 reply Please log in or register to add a comment.
0 0 votes true and false.….……... rish1602 answered Jan 30, 2021 rish1602 comment Share Follow 0 reply Please log in or register to add a comment.