⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 testmethod.java

📁 这是一张java应用教程的随书光盘
💻 JAVA
字号:
class Testmethod
{double x, y ;static float mark;
 float total(float a,float b)
     {
      float total;
      x=0.4;y=0.6;
      total=(float)(x* a+ y* b);
      return total;
    }
static void setmark(float i)
    { mark=i;}
static float getmark(  )
    {return mark ;}
public void display()
    {System.out.println("The total score"  + "=" + mark);	
    }
public static void main(String[] args) 
   {
	Testmethod tm = new Testmethod ();
	mark=tm.total(67,98);
	tm.display();
	tm.setmark(96);
	tm.display();
	}
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -