算法与数据结构实验题 3.9 文档
题解
撤销:撤销最近的一次的恢复和输入
恢复:恢复最近一次的撤销 但输入之前的撤销不可以
输入
建立栈word 输入和恢复//用数组建立的原因是要输出
建立栈del被撤销的输入在这里
#include<bits/stdc++.h>
using namespace std;
stack<string>del;
int main()
{
int top=-1;
string str;
string word[1000];
int n;
ci