惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

博客园 - 三生石上(FineUI控件)
Martin Fowler
Martin Fowler
月光博客
月光博客
AI
AI
B
Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
C
CXSECURITY Database RSS Feed - CXSecurity.com
WordPress大学
WordPress大学
GbyAI
GbyAI
L
Lohrmann on Cybersecurity
O
OpenAI News
Schneier on Security
Schneier on Security
P
Palo Alto Networks Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
T
Troy Hunt's Blog
V2EX - 技术
V2EX - 技术
W
WeLiveSecurity
L
LINUX DO - 最新话题
人人都是产品经理
人人都是产品经理
S
Security Affairs
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
A
Arctic Wolf
Recorded Future
Recorded Future
Microsoft Security Blog
Microsoft Security Blog
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
G
GRAHAM CLULEY
N
Netflix TechBlog - Medium
TaoSecurity Blog
TaoSecurity Blog
C
Check Point Blog
Scott Helme
Scott Helme
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
Apple Machine Learning Research
Apple Machine Learning Research
PCI Perspectives
PCI Perspectives
www.infosecurity-magazine.com
www.infosecurity-magazine.com
Vercel News
Vercel News
The Hacker News
The Hacker News
Y
Y Combinator Blog
Latest news
Latest news
SecWiki News
SecWiki News
Hugging Face - Blog
Hugging Face - Blog
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
Google Online Security Blog
Google Online Security Blog
Webroot Blog
Webroot Blog
Google DeepMind News
Google DeepMind News
Recent Commits to openclaw:main
Recent Commits to openclaw:main
C
Cisco Blogs
博客园_首页
H
Hackread – Cybersecurity News, Data Breaches, AI and More
宝玉的分享
宝玉的分享
L
LINUX DO - 热门话题

博客园 - 邢帅杰

.net core使用SharpZipLib压缩zip文件并设置密码 CSRedisCore用法 Android 常用数据目录(内部 / 外部、缓存、文件) 的 获取方法对照表 安卓把assets中的文件copy到app目录中 oracle执行sql语句前清除缓存 安卓开发使用interface自定义回调函数 安装DockerDesktop并启用 oracle中decode用法 vue使用import.meta编译报错,import.meta.env报:类型“ImportMeta”上不存在属性“env”。必须配置module。 oracle游标使用详解 oracle存储过程中声明一个行变量,接收游标中的行数据。variable_name table_name%ROWTYPE oracle NVL和NVL2 C#获取文件md5码 oracle查询存储过程和函数中是否包含某个字符串 Android清除WebView缓存 C#获取当前日期是星期几 切换项目git地址,项目迁移到新git地址 C#线程同步、跨进程同步Mutex详解、C#只允许运行一个实例 安卓打开第三方app并传入参数 安卓如何唤醒深度睡眠的设备并执行任务 java两个日期相差秒数
Android Stack说明
邢帅杰 · 2025-06-10 · via 博客园 - 邢帅杰

一、栈的定义
栈(Stack)是一种只允许在一端进行插入或者删除的操作的线性表。可以理解为一个桶里装进去的一层一层叠加压入进去的东西,栈的性质是进行先入后出的原则,也就是说最先进入栈的元素最后才出来。
Stack<String> stack = new Stack<String>();
stack.empty()判断一个栈是否为空。如果栈为空,该方法返回true;否则返回false。
stack.push(Object item)方法用于将指定元素压入栈顶。如果栈已满,它将抛出IllegalStateException。
stack.pop()方法用于删除并返回栈顶元素。如果栈为空,它将抛出EmptyStackException。
stack.peek()方法用于查看栈顶元素但不删除它。如果栈为空,它将抛出EmptyStackException。

posted on 2025-06-10 14:59  邢帅杰  阅读(70)  评论(0)    收藏  举报