Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- int main()
- {
- int arr[100],top;
- int n,i;
- scanf("%d",&n);
- ///push
- for(i=0;i<n;++i){
- scanf("%d",&arr[i]);
- top=i;
- }
- top++;
- arr[top]=55;
- printf("%d\n",arr[top]);
- ///pop
- top--;
- printf("%d",arr[top]);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement