Semaine 4, jour 4, soir

This commit is contained in:
gauvainboiche
2026-01-15 16:52:26 +01:00
parent 4c9c3b29e8
commit 54bb4d7628
17 changed files with 620 additions and 24 deletions

View File

@@ -0,0 +1,19 @@
from classes import Book, Library
library = Library("Romanesque")
def register_book(title: str, author: str):
book = Book(title, author)
return library.add_new_book(book)
def list_titles() -> list[str]:
return [book.title for book in library.list_books_in_list()]
def delete_book(title: str):
return library.take_out_book(title)
def search_by_letter(letter: str):
return library.search_book_by_letter(letter)
def search_by_word(word: str):
return library.search_book_by_word(word)