爱心代码集合
package Love;
public class Lover {
public static void main(String[] args) {
// TODO Auto-generated method stub
for(float y = (float) 1.5;y>-1.5;y -=0.15) {
for(float x= (float) -1.5;x<1.5;x+= 0.05){
float a = x*x+y*y-1;
if((a*a*a-x*x*y*y*y)<=0.0) {
System.out.print("$");
}
else
System.out.print(" ");
}
System.out.println();
}
}
}
package Love;
public class Ghh {
public static void main(String[] args) {
System.out.print("\t" + "*" + "\t\t\t\t\t\t\t\t\t\t\t\t" + "*" + "\t" + "\n");
System.out.print("*" + "\t\t" + "*" + "\t\t\t\t" + "帅 " + "\t\t\t\t\t" + "*" + "\t\t" + "*" + "\n");
System.out.print("\t" + "*" + "\t\t\t\t\t\t\t\t\t\t\t\t" + "*" + "\t" + "\n");
System.out.print("\t\t" + "*" + "\t\t\t\t\t\t\t\t\t\t" + "*" + "\t\t" + "\n");
System.out.print("\t\t\t" + "*" + "\t\t\t\t\t\t\t\t" + "*" + "\t" + "\n");
System.out.print("\t\t\t\t" + "*" + "\t\t\t\t\t\t" + "*" + "" + "\t" + "\n");
System.out.print("\t\t\t\t\t" + "*" + "\t\t\t\t" + "*" + "" + "\t\t" + "\n");
System.out.print("\t\t\t\t\t\t" + "*" + "\t\t" + "*" + "" + "\t\t" + "\n");
System.out.print("\t\t\t\t\t\t\t" + "*" + "\n");
}
标签:1.5,代码,float,System,print,爱心,集合,public,out From: https://www.cnblogs.com/yzk5/p/17644567.html