摘要: 这次老师没有发题目,内容大致如下:(加上了个人的修改) 二话不说上代码。这次算上两个接口和一个主类,总共有11个文件。 1.Card.java源文件: package BusCard; public class Card { Card(){ System.out.println("A Card ha 阅读全文
posted @ 2021-04-22 17:58 GrayGooStorm 阅读(305) 评论(0) 推荐(0) 编辑
摘要: //AppMain中嵌套了Doll类,下面这个程序简单举例 //由于过于简单,所以不多加注释了 package room; public class AppMain { public static void main(String[] args) { // TODO Auto-generated m 阅读全文
posted @ 2021-03-04 15:04 GrayGooStorm 阅读(106) 评论(0) 推荐(0) 编辑
摘要: /*每次产生5个随机减法算术题,提示用户输入答案,并判断是否正确,最后显示正确答案以及答题时间涉及知识点:1.随机数的生成方法Math.random()2.条件分支语句if3.获取时间System.currentTimeMillis(),4.三元运算符代替if5.String 的巧妙使用 */pac 阅读全文
posted @ 2021-02-24 19:11 GrayGooStorm 阅读(146) 评论(0) 推荐(0) 编辑
摘要: package Example;/* 随机产生10以内的两个整数number1和number2,显示算式, 例如“What is 7 plus 9 ?”,输入答案后,提示答案是否正确。 产生随机数的方法:System.currentTimeMillis(), 这个方法获得系统当前时间到1970.1. 阅读全文
posted @ 2021-02-23 22:09 GrayGooStorm 阅读(247) 评论(0) 推荐(0) 编辑
摘要: 将较长的数据类型转换成较短的数据类型,只能用强制类型转换。形如: short s; Byte b = (byte)s; 7种类型的顺序排列如下: byte < (short = char) < int < long < float < double 其中,short和char之间也必须强制转换。 这 阅读全文
posted @ 2021-02-20 19:58 GrayGooStorm 阅读(601) 评论(0) 推荐(0) 编辑
摘要: ///c语言 ///按指示输入二叉树,并输入一个节点 ///能得到根到该结点的路径 ///本人的编程基础粗劣且笨拙,见谅#include<stdio.h> #include<stdlib.h>typedef char TElemType;typedef struct BiTNode { TElemT 阅读全文
posted @ 2020-04-16 11:59 GrayGooStorm 阅读(432) 评论(0) 推荐(0) 编辑
摘要: #武汉加油!import turtle as tt.pensize(20)t.pencolor("blue")t.setup(1700, 600) t.penup()#-t.goto(-400,150)t.pendown()t.goto(-320,150) t.penup()#--t.goto(-4 阅读全文
posted @ 2020-02-20 19:25 GrayGooStorm 阅读(1298) 评论(0) 推荐(0) 编辑
摘要: #include<stdio.h> //Made by Shi Shuangming#include<stdlib.h> //调用几个比较怪异的头文件#include<conio.h>int main(){ int i,j,x=5,y=10; char input; int isfire=0; fo 阅读全文
posted @ 2019-11-08 13:33 GrayGooStorm 阅读(504) 评论(0) 推荐(0) 编辑