摘要: 1 #include 2 #include 3 #include 4 5 6 7 struct student{ 8 char name [20]; 9 char num[10]; 10 int age ; 11 12 }; 13 14 struct Node{ 15 struct student data... 阅读全文
posted @ 2019-06-18 11:15 Ssinoo団子 阅读(857) 评论(0) 推荐(0) 编辑
摘要: 运行代码👇 阅读全文
posted @ 2019-06-13 19:49 Ssinoo団子 阅读(1483) 评论(2) 推荐(0) 编辑
摘要: import java.util.HashMap;import java.util.Scanner;public class Demo01Map { public static void main(String[] args) { //1,使用Scanner获得用户输入的字符串 Scanner scanner = new Scanner(System.in);... 阅读全文
posted @ 2019-06-10 20:39 Ssinoo団子 阅读(271) 评论(0) 推荐(0) 编辑
摘要: /* 练习: 计算一个字符串中每个字符的出现次数 分析: 1,使用Scanner获得用户输入的字符串 2,创建Map集合,kep是字符串的字符,value是字符的个数 3,遍历字符串,获取每一个字符 4,使用获取到在字符,去Map集合判断key是否存在 key存在: ... 阅读全文
posted @ 2019-06-05 20:48 Ssinoo団子 阅读(1312) 评论(0) 推荐(0) 编辑
摘要: 运行代码↓ 阅读全文
posted @ 2019-06-04 16:07 Ssinoo団子 阅读(1489) 评论(0) 推荐(0) 编辑
摘要: import java.util.ArrayList;import java.util.Collection;/* 增强for循环 格式: for(集合/数组的数据类型 变量名:集合名/数组名){ sout(变量名) } */public class Demo02Foreach { public static void main(Stri... 阅读全文
posted @ 2019-06-03 20:45 Ssinoo団子 阅读(755) 评论(0) 推荐(0) 编辑
摘要: import java.util.ArrayList;import java.util.Collection;import java.util.Iterator;/* java.util.Iterator接口 两个常用的方法 boolean hasNext()如果有元素可以迭代,返回ture E n 阅读全文
posted @ 2019-06-03 20:43 Ssinoo団子 阅读(174) 评论(0) 推荐(0) 编辑
摘要: 1 import org.junit.Test; 2 3 import java.util.HashSet; 4 import java.util.LinkedHashSet; 5 import java.util.Set; 6 import java.util.TreeSet; 7 8 public class TestSet { 9 /* 10 ... 阅读全文
posted @ 2019-06-03 19:35 Ssinoo団子 阅读(152) 评论(0) 推荐(0) 编辑
摘要: 运行 代码↓ 阅读全文
posted @ 2019-05-28 20:28 Ssinoo団子 阅读(1822) 评论(0) 推荐(0) 编辑
摘要: 1 #ifndef LINKLIST_H 2 #define LINKLIST_H 3 4 #include 5 #include 6 7 //链表结点 8 typedef struct LINKNODE { 9 void* data; //指向任何类型的数据 10 struct LINKENODE* next; 11 }LinkNode; 12 13... 阅读全文
posted @ 2019-05-27 19:26 Ssinoo団子 阅读(458) 评论(0) 推荐(0) 编辑