Ugrás a fő tartalomra
🔒 Előnézet mód. Az első tizenöt Foundations lecke ingyenes; ez Pro. Indíts 7 napos trial-t, hogy feloldd a szerkesztőt, az AI tippeket és a tananyag többi részét. Kártya szükséges, bármikor lemondhatod a Dashboard-ban.7 napos trial indítása →
⚡
← Kurzusok›Interview Prep1. modul · Big-O és egyszerű minták›Tolóablak: a leghosszabb egyedi részkarakterláncwrite5 / 104
+100 XP
Feladat🌐 shown in EN
📝 **Task:** Write `longest_unique(s)` returning the length of the longest substring of `s` with all distinct characters. Print `longest_unique('abcabcbb')`. 📋 Implement the function above. Test cases run automatically. 💡 **Hint:** Re-read the theory if you get stuck — the pattern is right there.
✏️ Írd ide a kódodat
🐍
Python betöltése...
Egyszeri letöltés (~1 MB). Utána azonnal fut.
📊 Eredmény
Kattints a Futtatásra az eredmény megtekintéséhez...