最近小弟再学 java ,看书看到一半有个看不懂的例子
public class StackTest{
private double [] doubleElements = {1.11,2.11,3.11,4.11};
private int [] integerElements = {1,2,3,4,5,6};
private Stack< Double > doubleStack;
private Stack< Integer > integerStack;
public void testStacks(){
doubleStack = new Stack< Double >(5);
integerStack = new Stack< Integer >(10);
testPushDouble();
testPushInteger();
}
public void testPushDouble(){
System.out.println("\n将元素放到 double 资料型态的stack ");
for( double element : doubleElem ..
访客只能看到部份内容,免费 加入会员 或由脸书 Google 可以看到全部内容