質問編集履歴
3
修正
title
CHANGED
File without changes
|
body
CHANGED
@@ -39,7 +39,6 @@
|
|
39
39
|
attr_accessor :artist, :year, :songs
|
40
40
|
|
41
41
|
def initialize(name, price)
|
42
|
-
super(name: name, price: price)
|
43
42
|
self.artist = artist
|
44
43
|
self.year = year
|
45
44
|
self.songs = songs
|
2
修正
title
CHANGED
File without changes
|
body
CHANGED
@@ -38,7 +38,7 @@
|
|
38
38
|
# 編集
|
39
39
|
attr_accessor :artist, :year, :songs
|
40
40
|
|
41
|
-
def initialize(name
|
41
|
+
def initialize(name, price)
|
42
42
|
super(name: name, price: price)
|
43
43
|
self.artist = artist
|
44
44
|
self.year = year
|
1
修正
title
CHANGED
File without changes
|
body
CHANGED
@@ -18,11 +18,9 @@
|
|
18
18
|
|
19
19
|
class Book < Product
|
20
20
|
# 編集
|
21
|
-
require "./product"
|
22
21
|
attr_accessor :author, :publisher, :page_count
|
23
22
|
|
24
|
-
def initialize(name:, price:, author:, publisher:, page_count: )
|
25
|
-
|
23
|
+
def initialize(name, price)
|
26
24
|
self.author = author
|
27
25
|
self.publisher = publisher
|
28
26
|
self.page_count = page_count
|
@@ -38,10 +36,9 @@
|
|
38
36
|
|
39
37
|
class CD < Product
|
40
38
|
# 編集
|
41
|
-
require "./product"
|
42
39
|
attr_accessor :artist, :year, :songs
|
43
40
|
|
44
|
-
def initialize(name:, price
|
41
|
+
def initialize(name:, price)
|
45
42
|
super(name: name, price: price)
|
46
43
|
self.artist = artist
|
47
44
|
self.year = year
|