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.
  • Practice
  • Certification
  • Compete
  • Career Fair
  • Hiring developers?
  1. Practice
  2. Data Structures
  3. Stacks
  4. Simple Text Editor
  5. Discussions

Simple Text Editor

Problem
Submissions
Leaderboard
Discussions

    You are viewing a single comment's thread. Return to all comments →

  • mayank_k_jha 4 years ago+ 0 comments

    In this problem,by using stack,the basic idea is to store each modified string after the append or delete operation performed on them. Now the fourth option is to undo last step on string and as the previous modified(last modified) string must be on the top of stack so here we have to pop it(st.pop()).After poping,the top of stack will now point that string which it was before performing the last modification operation (append or delete) on it and we will now store its present top element in s ie s=st.peek()

    7|
    ParentPermalink
  • Contest Calendar
  • Blog
  • Scoring
  • Environment
  • FAQ
  • About Us
  • Support
  • Careers
  • Terms Of Service
  • Privacy Policy
  • Request a Feature