摘要:
主函数测试方法: public class TestATM { public static void main(String[] args) { ABCATM a = new ABCATM(); //ICBCImpl icbc = new ICBCImpl(3000, "123456");//工商卡
阅读全文
posted @ 2017-06-01 13:42
两枝梅
阅读(242)
推荐(0)
摘要:
UnionPay接口:用于描述银联统一指定的规则 public interface UnionPay { /* * 接口:用于描述银联统一指定的规则 */ public double getBalance();//查看余额 public boolean drawMoney(double number
阅读全文
posted @ 2017-06-01 11:00
两枝梅
阅读(498)
推荐(0)
摘要:
抽象类:Shape public abstract class Shape { protected double c; public abstract double area();} 类Square正方形,继承抽象类 public class Square extends Shape{ public
阅读全文
posted @ 2017-06-01 09:56
两枝梅
阅读(524)
推荐(0)
摘要:
import java.util.Arrays;import java.util.Random;public class BubbleSort { public static void main(String[] args){ //创建数组 int[] arr = new int[10]; Rand
阅读全文
posted @ 2017-05-31 15:43
两枝梅
阅读(88)
推荐(0)
摘要:
import java.util.Arrays;import java.util.Random;public class MaxOfArray { public static void main(String[] args){ //创建一个10个长度的数组 int[] arr = new int[1
阅读全文
posted @ 2017-05-31 15:33
两枝梅
阅读(558)
推荐(0)
摘要:
import java.util.Arrays;import java.util.Random;public class MaxOfArray { public static void main(String[] args){ //创建一个10个长度的数组 int[] arr = new int[1
阅读全文
posted @ 2017-05-31 15:29
两枝梅
阅读(453)
推荐(0)
摘要:
public class MultiplicationTable { public static void main(String[] args){ //i变量用于控制行数 for(int i=1;i<10;i++){ //j变量用于控制每行中参与计算的最大数值:与行数相等 for(int j=1;
阅读全文
posted @ 2017-05-31 15:23
两枝梅
阅读(138)
推荐(0)
摘要:
import java.util.Scanner;public class AddCode { public static void main(String[] args){ System.out.println("即将开始10次加法测试。。。"); Scanner sc = new Scanner
阅读全文
posted @ 2017-05-31 15:15
两枝梅
阅读(287)
推荐(0)
摘要:
import java.util.Scanner;public class NumberGuessV02 { public static void main(String[] args){ //生成一个随机数 int num = (int)(Math.random()*1000)+1; //准备输入
阅读全文
posted @ 2017-05-31 14:30
两枝梅
阅读(695)
推荐(0)
摘要:
import java.util.Scanner;public class GuessingGame { public static void main(String[] args){ int count = 0; char[] input = null; int[] result = new in
阅读全文
posted @ 2017-05-31 14:22
两枝梅
阅读(237)
推荐(0)