🔒 Način pregleda. Prvih petnaest Foundations lekcija je besplatno; ova je Pro. Pokrenite 7-dnevni trial da otključate editor, AI savjete i ostatak programa. Kartica obavezna, otkažite bilo kada u Dashboard.Pokreni 7-dnevni trial →
📝 **Question:** Predict the two lines printed. \`.name\` returns the final segment ("today.log"); \`.suffix\` returns the extension with the dot.
📋 Pick the right answer.
💡 **Hint:** Re-read the theory above if unsure.
Predvidi izlaz
Pažljivo pročitaj kod
from pathlib import Path
p = Path("data") / "logs" / "today.log"
print(p.name)
print(p.suffix)