初心者の質問については申し訳ありませんが、プログラミングはかなり新しいです。私の質問は、親クラスから必要以上の属性を継承する場合、それらの属性の1つを別の属性と等しく設定するにはどうすればよいですか?ここに例があります:
class numbers():
def __init__(self, x, y, z):
# x, y and z initialized here
class new_numbers(numbers):
def __init__(self, x, y):
numbers.__init__(self, x, y=x, z)
# what im trying to do is get the y attribute in the subclass to be equal to the x attribute, so that when the user is prompted, they enter the x and z values only.
ご協力いただきありがとうございます!