حليت التحدي، ولكن الكود مستحيل أن يفهمه شخص آخر، رغم أنه يعطي نفس النتيجة
Books=[]
own_book=input("Enter the name of a book you won:\n").lower()
Books.append(own_book)
another_book=input("Enter the name of another book you own or press 'Enter' to skip:\n").lower()
Books.append(another_book)
print(f"Your library: {Books}")
wish_list=[]
future_book=input("Enter name of a book you wish to have in the future:\n").lower()
wish_list.append(future_book)
wish=input("enter a name of another book you wish to have or press 'Enter' to skip:)\n").lower()
if wish== wish :
wish_list.append(wish)
print(f"Your wishlist:{wish_list}")
oldwisht=[]
all_books=input("Enter the name of a book from your wishlist that you've or press 'enter' to skip:\n").lower()
oldwisht.append(all_books)
oldwisht.append(another_book)
oldwisht.append(own_book)
update_wish=[]
update_wish.append(future_book)
if oldwisht==oldwisht:
print(f"Update library {oldwisht}")
print(F"Update wishlist {update_wish}")
wish_done=input("Enter a book for your library you wish to donate or press 'Enert' to skip:\n").lower()
Finish=[own_book,another_book,all_books]
Finish.remove(another_book)
print (f"finaliy your library after donations:{Finish}")