• 个人简介

    #手撕栈模板ddd

    #include <bits/stdc++.h>
    using namespace std;
    int arr[10000];
    int top=0;
    void push(int x){
    	arr[++top]=x;
    	
    }bool empty(){
    	return top==0;
    }int Top(){
    	return arr[top];
    }void pop(){
    	top--;
    }int size(){
    	return top;
    }
    
    int main(){
    	push(1);
    	push(666);
      
    	push(666666);
    	pop();
    	cout<<Top();
    	
    	
    	return 0;
    }
    

    ##头文件

    #include <bits/stdc++.h>
    using namespace std;
    int main(){
    	return 0;
    }
    
  • 通过的题目

  • 最近活动

题目标签

初窥门径
2
顺序结构
2