From f393a6fe48068f2f0e4094f215ea3891d70d4fbe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=84=E4=BF=8A=E6=B4=81?= <17759877219@163.com> Date: Mon, 22 Apr 2024 00:21:53 +0800 Subject: [PATCH 1/3] feat:. --- .../Main.java" | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 "work/com/java/minxi/java_20240419/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Main.java" diff --git "a/work/com/java/minxi/java_20240419/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Main.java" "b/work/com/java/minxi/java_20240419/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Main.java" new file mode 100644 index 0000000..e1921ad --- /dev/null +++ "b/work/com/java/minxi/java_20240419/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Main.java" @@ -0,0 +1,7 @@ +package com.java.minxi.java_20240419.java_2302_黄俊洁_2344310247; + +public class Main { + public static void main(String[] args) { + System.out.println("hjj"); + } +} -- Gitee From 6bc2d7867176cf257abc1dd812397df84383372b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=84=E4=BF=8A=E6=B4=81?= <17759877219@163.com> Date: Tue, 23 Apr 2024 20:41:08 +0800 Subject: [PATCH 2/3] =?UTF-8?q?feat:=E6=9C=AA=E5=AE=8C=E6=88=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Hjj.java" | 55 +++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 "work/com/java/minxi/java_20240423/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Hjj.java" diff --git "a/work/com/java/minxi/java_20240423/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Hjj.java" "b/work/com/java/minxi/java_20240423/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Hjj.java" new file mode 100644 index 0000000..06125ad --- /dev/null +++ "b/work/com/java/minxi/java_20240423/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Hjj.java" @@ -0,0 +1,55 @@ +package com.java.minxi.java_20240423.java_2302_黄俊洁_2344310247; + +public class Hjj { + + String brand; + + int weight; + + String type; + + public void Laundry() { + System.out.println(brand+type+"洗衣服"); + } + + public void Cook(){ + System.out.println(brand+type+"做饭"); + } + + public void Weight(){ + System.out.println(brand+type+weight+"称重"); + } + + public Hjj(){ + } + + public Hjj(String brand,int weight,String type){ + this.brand=brand; + this.weight=weight; + this.type=type; + } + + public String getBrand(){ + return brand; + } + + public void setBrand(){ + this.brand=brand; + } + + public int getWeight(){ + return weight; + } + + public void setWeight(){ + this.weight=weight; + } + + public String getType(){ + return type; + } + + public void setType(){ + this.type=type; + } + } -- Gitee From 92ecf6bfdf8ad5df6fcea896cdcec7e65466848e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=84=E4=BF=8A=E6=B4=81?= <17759877219@163.com> Date: Wed, 24 Apr 2024 00:03:32 +0800 Subject: [PATCH 3/3] =?UTF-8?q?feat:=E6=8F=90=E4=BA=A4=E4=BD=9C=E4=B8=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Hjj.java" | 97 +++++++++++++------ .../Main.java" | 64 ++++++++++++ 2 files changed, 133 insertions(+), 28 deletions(-) create mode 100644 "work/com/java/minxi/java_20240423/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Main.java" diff --git "a/work/com/java/minxi/java_20240423/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Hjj.java" "b/work/com/java/minxi/java_20240423/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Hjj.java" index 06125ad..db42bca 100644 --- "a/work/com/java/minxi/java_20240423/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Hjj.java" +++ "b/work/com/java/minxi/java_20240423/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Hjj.java" @@ -2,54 +2,95 @@ package com.java.minxi.java_20240423.java_2302_黄俊洁_2344310247; public class Hjj { - String brand; + String brand; - int weight; + int weight; - String type; + String type; - public void Laundry() { - System.out.println(brand+type+"洗衣服"); - } + public void Laundry() { + System.out.println(brand + type + "洗衣服"); + } - public void Cook(){ - System.out.println(brand+type+"做饭"); - } + public void Cook() { + System.out.println(brand + type + "做饭"); + } - public void Weight(){ - System.out.println(brand+type+weight+"称重"); - } + public void Weight() { + System.out.println(brand + type + weight + "称重"); + } - public Hjj(){ + public Hjj() { + } + + public Hjj(String brand, int weight, String type) { + this.brand = brand; + this.weight = weight; + this.type = type; + } + + public String getBrand() { + return brand; + } + + public void setBrand(String 海尔) { + this.brand = brand; + } + + public int getWeight() { + return weight; + } + + public void setWeight(int i) { + this.weight = weight; + } + + public String getType() { + return type; + } + + public void setType(String 冰箱) { + this.type = type; + } + + + public static class Rec { + + String brand; + String type; + + public void cold() { + System.out.println(brand + type + "正在制冷"); } - public Hjj(String brand,int weight,String type){ - this.brand=brand; - this.weight=weight; - this.type=type; + public void hot() { + System.out.println(brand + type + "正在制热"); } - public String getBrand(){ + + public String getBrand() { return brand; } - public void setBrand(){ - this.brand=brand; + public void setBrand(String brand) { + this.brand = brand; } - public int getWeight(){ - return weight; + public String getType() { + return type; } - public void setWeight(){ - this.weight=weight; + public void setType(String type) { + this.type = type; } - public String getType(){ - return type; + public Rec() { } - public void setType(){ - this.type=type; + public Rec(String brand, String type) { + this.brand = brand; + this.type = type; } } + +} diff --git "a/work/com/java/minxi/java_20240423/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Main.java" "b/work/com/java/minxi/java_20240423/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Main.java" new file mode 100644 index 0000000..d0d38ca --- /dev/null +++ "b/work/com/java/minxi/java_20240423/java_2302_\351\273\204\344\277\212\346\264\201_2344310247/Main.java" @@ -0,0 +1,64 @@ +package com.java.minxi.java_20240423.java_2302_黄俊洁_2344310247; + +public class Main { + public static void main(String[] args) { + Hjj e1 = new Hjj(); + e1.brand = "海尔"; + e1.type = "洗衣机"; + e1.Laundry(); + + Hjj e2 = new Hjj(); + e2.brand = "美的"; + e2.type = "电饭锅"; + e2.Cook(); + + Hjj e3 = new Hjj(); + e3.brand = "海尔"; + e3.type = "冰箱"; + e3.weight = 50; + e3.Weight(); + + Hjj.Rec e4 = new Hjj.Rec(); + e4.brand = "大金"; + e4.type = "空调"; + e4.cold(); + + System.out.println("-------------------"); + + Hjj e5 = new Hjj(); + e5.setBrand("海尔"); + e5.setType("洗衣机"); + e5.Laundry(); + + Hjj e6 = new Hjj(); + e6.setBrand("美的"); + e6.setType("电饭锅"); + e6.Cook(); + + Hjj e7 = new Hjj(); + e7.setBrand("海尔"); + e7.setType("冰箱"); + e7.setWeight(50); + e7.Weight(); + + Hjj.Rec e8 = new Hjj.Rec(); + e8.setBrand("大金"); + e8.setType("空调"); + e8.cold(); + + System.out.println("-------------------"); + + Hjj e9 = new Hjj("海尔",0,"洗衣机"); + e9.Laundry(); + + Hjj e10 = new Hjj("美的",0,"电饭锅"); + e10.Cook(); + + Hjj e11 = new Hjj("海尔",50,"冰箱"); + e11.Weight(); + + Hjj.Rec e12 = new Hjj.Rec("大金","空调"); + e12.cold(); + + } +} -- Gitee