Base di conoscenzaCentro esami
ITItaliano
Scegli la lingua13

CKTIS / Base di conoscenza

Base di conoscenza

Sintassi, operatori e concetti di programmazione. Trova una spiegazione, consulta un esempio e torna a imparare.

Voci: 5788

Python

itertools.zip_longest

Abbina posizioni corrispondenti fino a esaurire l’ingresso più lungo.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

list.append

Aggiunge esattamente un oggetto alla fine della lista esistente.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

list.clear

Rimuove tutti gli elementi della lista esistente e restituisce None.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

list.copy

Crea una copia superficiale, cioè una lista nuova con riferimenti agli stessi elementi.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

list.count

Conta gli elementi che sono lo stesso oggetto cercato o che risultano uguali ad esso.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

list.extend

Aggiunge in successione gli elementi di un iterabile alla lista esistente.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

list.index

Restituisce l’indice da zero del primo elemento uguale; start e stop facoltativi limitano la ricerca escludendo stop.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

list.insert

Inserisce prima della posizione scelta limitando gli indici estremi alle posizioni disponibili per l’inserimento.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

list.pop

Rimuove e restituisce l’elemento indicizzato.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

list.remove

Rimuove il primo elemento che sia lo stesso oggetto cercato o che risulti uguale ad esso.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

list.reverse

Inverte le posizioni nella lista esistente senza confrontare gli elementi.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

list.sort

Ordina la lista sul posto e restituisce None.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

logging.basicConfig

basicConfig imposta con level la soglia del logger radice e configura flusso e formato di uscita.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

logging.critical

critical segnala al logger radice un evento di livello CRITICAL con valore 50.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

logging.debug

debug invia diagnostica di livello DEBUG (10) al logger radice.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

logging.error

error invia al logger radice un evento di livello ERROR (40).

Intermedio · Python 3.14; repository image, production runtime not attested
Python

logging.exception

exception registra un evento ERROR con exc_info=True per impostazione predefinita.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

logging.Formatter

Formatter compone gli attributi del record come levelname e message in un testo.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

logging.getLogger

getLogger restituisce lo stesso logger per un nome nell’interprete e la radice senza nome.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

logging.info

info registra l’avanzamento normale al livello INFO (20).

Intermedio · Python 3.14; repository image, production runtime not attested
Python

logging.INFO — livello informativo

logging.INFO è la costante 20, che identifica gli eventi durante il normale funzionamento del programma. Usarla come soglia ammette INFO e i livelli superiori, ma esclude DEBUG.

Base · Python 3.14; repository image, production runtime not attested
Python

logging.Logger

Un Logger con nome ottenuto da getLogger controlla livello effettivo e filtri prima di inviare il record.

Intermedio · Python 3.14; repository image, production runtime not attested
Python

LoggerAdapter.info — logging contestuale

LoggerAdapter.info registra un messaggio INFO con il contesto dell’adattatore, ad esempio un identificativo della richiesta. Scopri la differenza tra la gestione predefinita di extra e merge_extra=True.

Intermedio · Python 3.14; repository image, production runtime not attested