LLD - Design — Library Management System
Given this Python code snippet, what will be the output?
Assuming Loan class stores book and member as attributes.
class Book:
def __init__(self, title):
self.title = title
class Member:
def __init__(self, name):
self.name = name
loan = Loan(Book('1984'), Member('Alice'))
print(loan.book.title, loan.member.name)Assuming Loan class stores book and member as attributes.
