0914 段階3 <余裕がある人向け>を追加

This commit is contained in:
2026-09-14 16:22:39 +09:00
parent 1b2d0829d1
commit ffe4c91806
2 changed files with 8 additions and 4 deletions

View File

@@ -7,5 +7,9 @@ public class Item {
public void sell(int amount) {
this.stock = this.stock - amount;
}
public int totalPrice() {
return this.price*this.stock;
}
}