public class Text1 {
public static void main(String[] args) {
System.out.println("welcome java");
System.out.println("hello world");
System.out.println("hello javaee");
}
}
public class Text2 {
public static void main(String[] args) {
for(int i=1;i<=5;i++) {
System.out.println("show your massage");
}
}
}
public class Text3 {
public static void main(String[] args) {
System.out.println(" J A V V A");
System.out.println(" J A A V V A A");
System.out.println("J J AAAAA V V AAAAAAA");
System.out.println(" JJ A A V A A");
}
}
public class Text4 {
public static void main(String[] args) {
System.out.println("a"+"\t"+"a^2"+"\t"+"a^3");
System.out.println("1"+"\t"+"1"+"\t"+"1");
System.out.println("2"+"\t"+"4"+"\t"+"8");
System.out.println("3"+"\t"+"9"+"\t"+"27");
System.out.println("4"+"\t"+"16"+"\t"+"64");
}
}
public class Text5 {
public static void main(String[] args) {
System.out.println("1+2+......+100的和为:"+(101)*100/2);
}
}
import java.util.Scanner;
public class Text7 {
public static void main(String[] args) {
System.out.println("请输入圆的半径:");
Scanner s=new Scanner(System.in);
double r=s.nextDouble();
double PI=3.14;
double perimeter=r*2*PI;
double are=r*r*PI;
System.out.println("周长为:"+perimeter+"面积为:"+are);
}
}
public class Text9 {
public static void main(String[] args) {
double a=312032486;
double day=365*24*60*60;
System.out.println("第五年:"+(a+(5*day)/7.0-(5*day)/13.0-(5*day)/45.0));
}
}
public class Text10 {
public static void main(String[] args) {
System.out.println("x的值为:"+(44.5*0.55-50.2*5.9)/(3.4*0.55-50.2*2.1));
System.out.println("y的值为:"+(3.4*5.9-44.5*2.1)/(3.4*0.55-50.2*2.1));
}
}