We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
how does pop() method work in sets if it is unordered ?
why is it set working like an ordered data structure in this question when I am running test cases and changing the last number in my input, pop always removs the last element, how does it know if it is not iterable ?
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Set .discard(), .remove() & .pop()
You are viewing a single comment's thread. Return to all comments →
how does pop() method work in sets if it is unordered ? why is it set working like an ordered data structure in this question when I am running test cases and changing the last number in my input, pop always removs the last element, how does it know if it is not iterable ?