TQC107- public class JPD01 {
- public static void main(String argv[]) {
- int action = 1, skill = 2, teamgame = 3;
- System.out.println("The basketball grade is " + Basketball.calGrade(_____________________));
- System.out.println("The baseball grade is " + _______________(________________________));
- }
- }
- class Basketball {
- ...... {
- return a + s + t;
- }
- }
- class Baseball {
- ...... {
- return 10 + s + t;
- }
- }
複製代碼 TQC110- import java.util.Scanner;
- public class JPD01 {
- public static void main(String args[]) {
- double totalarea;
- System.out.printf("圓形面積為:%f \n",calCircle(5));
- System.out.printf("三角形面積為:%f \n",________________);
- System.out.printf("方形面積為:%f \n",_______________);
- totalarea = __________________________________________;
- System.out.printf("此圖形面積為:%f \n",totalarea);
- }
- _______ ______ calCircle(_____) {
-
- }
- ______ ____ calTriangle(_____________) {
-
- }
- ______ ____ calRectangle(______________) {
-
- }
- }
複製代碼 |