摘要: //计算器类 class Calculator{ private int num1; //操作数1 private int num2; //操作数2 private char option ; //运算符 //提供公共的方法设置属性值.... public void initCalculator(i 阅读全文
posted @ 2019-04-28 14:50 18软件工程五班陈星星 阅读(452) 评论(1) 推荐(0) 编辑
摘要: 集合:可变的数据类型,他里面的元素必须是不可变的数据类型,无序,不重复。 {}'''# set1 = set({1,2,3})# set2 = {1,2,3,[2,3],{'name':'alex'}} # 错的# print(set1)# print(set2)# set1 = {'alex',' 阅读全文
posted @ 2019-04-27 22:55 18软件工程五班陈星星 阅读(204) 评论(0) 推荐(0) 编辑
摘要: public class arrayTool { public static String toString(int arr[]){ String result = ""; for(int i = 0;i < arr.length;i++) { if(i == 0) { result+="["+ar 阅读全文
posted @ 2019-04-25 15:14 18软件工程五班陈星星 阅读(182) 评论(0) 推荐(0) 编辑
摘要: import os.pathwhile True: rootdir=input('请输入遍历文件夹的绝对路径:(q退出)') if rootdir=='q': break if not(os.path.exists(rootdir)): print("输入的路径不存在,请重新输入!!") conti 阅读全文
posted @ 2019-04-24 23:19 18软件工程五班陈星星 阅读(259) 评论(0) 推荐(0) 编辑
摘要: import randomx = random.randint(0,99)while(True): num = input("please input a number\n") if(num.isdigit): num = int(num) if(x == num) : print("congrat 阅读全文
posted @ 2019-04-24 16:57 18软件工程五班陈星星 阅读(1752) 评论(0) 推荐(0) 编辑
摘要: #include<stdio.h>#include<assert.h>#include<malloc.h> #define ElemType int typedef struct Node{ ElemType data; struct Node *next;}Note,*PNode; typedef 阅读全文
posted @ 2019-04-22 16:26 18软件工程五班陈星星 阅读(256) 评论(0) 推荐(0) 编辑
摘要: #include<stdio.h>#include<malloc.h>#include<assert.h>#define SEQLIST_INIT_SIZE 8#define INC_SIZE 3typedef int ElemType; typedef struct SeqList{ ElemTy 阅读全文
posted @ 2019-04-11 20:00 18软件工程五班陈星星 阅读(242) 评论(0) 推荐(0) 编辑