摘要: 链栈: 链栈结构的定义: 链栈即栈的链式存储,这里用带头结点的单链表实现链栈 1 typedef int StackElemType; 2 typedef struct node { 3 StackElemType data; 4 struct node* next; 5 }LinkStackNod 阅读全文
posted @ 2020-11-11 20:04 笺笙 阅读(115) 评论(0) 推荐(0) 编辑
摘要: 用户注册时需要给用户填写的邮箱发送一封激活邮件 一、引入jar包: mail.jar activation.jar 二、发送邮件的工具类 1 public class MailUtils extends Thread { 2 //给用户发送邮件的邮箱 3 private String from = 阅读全文
posted @ 2020-11-11 18:26 笺笙 阅读(111) 评论(0) 推荐(0) 编辑
摘要: 顺序栈 顺序栈的存储结构定义: 1 #include <stdio.h> 2 #include <stdlib.h> 3 #define Stack_Size 20 4 typedef char StackElementType; 5 typedef struct { 6 StackElementT 阅读全文
posted @ 2020-10-03 20:59 笺笙 阅读(194) 评论(0) 推荐(0) 编辑
摘要: 线性表的链式存储 单链表存储结构的定义: 1 #include <stdio.h> 2 #include <stdlib.h> 3 typedef int ElemType; 4 typedef struct Node { /*结点类型定义*/ 5 ElemType data; 6 struct N 阅读全文
posted @ 2020-10-03 20:20 笺笙 阅读(142) 评论(0) 推荐(0) 编辑
摘要: 线性表的顺序存储: 线性表顺序存储结构的定义: 1 #include <stdio.h> 2 #include <stdlib.h> 3 #define MAXSIZE 100 4 typedef int ElemType; /*给int类型定义一个别名*/ 5 typedef struct { 6 阅读全文
posted @ 2020-10-03 20:15 笺笙 阅读(234) 评论(0) 推荐(0) 编辑
摘要: 1 public class Main { 2 public static void main(String[] args) { 3 // write your code here 4 int[] arr = {4,3,2,3,5,9,1,10}; 5 int max = getMax(arr); 阅读全文
posted @ 2020-08-30 23:05 笺笙 阅读(280) 评论(0) 推荐(0) 编辑
摘要: 双列集合 Map:用于存储具有键、值映射关系的元素,每一个元素都包含一对键值,可以通过指定的键找到对应的值 关系图 1.HashMap集合 (1)HashMap的介绍 HashMap:Map接口的实现类,用于存储键值映射关系 HashMap特点:键相同,值覆盖 (2)HashMap简单应用 1 pu 阅读全文
posted @ 2019-08-19 15:30 笺笙 阅读(324) 评论(0) 推荐(0) 编辑
摘要: 1.Iterator接口 (1)Iterator迭代器的作用: iterator主要用于遍历Collection中的元素 (2)Iterator遍历集合的过程: 当遍历集合时,首先调用集合的iterator()方法获取迭代器对象,使用hashNext()判断是否存在下一个元素, 如果存在(hashN 阅读全文
posted @ 2019-08-14 15:38 笺笙 阅读(248) 评论(0) 推荐(0) 编辑
摘要: 单列集合 Collection:用于存储一系列符合某种规则的元素,它有三个子接口分别为List和Set和Queue 关系图 一.List集合 List的特点:所有元素是以一种线性方式进行存储,元素有序,可重复(存入顺序和取出顺序一致) 1.ArrayList集合 (1)ArrayList介绍 Arr 阅读全文
posted @ 2019-08-14 10:24 笺笙 阅读(464) 评论(0) 推荐(0) 编辑
摘要: Activity的生命周期 生命周期状态 1. 启动状态:Activity的启动状态很短,一般情况下,Activity启动之后便会进入运行状态 2. 运行状态:Activity获取焦点、可见,可以与用户进行交互 3. 暂停状态:Activity无法获取焦点,用户对它操作没有响应 4. 停止状态:Ac 阅读全文
posted @ 2019-07-01 16:23 笺笙 阅读(479) 评论(0) 推荐(0) 编辑