Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Lære With broken test | First Section
Explain Unit test on grid chapter

Sveip for å vise menyen

book
With broken test

Here test broken

Oppgave

Swipe to start coding

You have a list of integers stored in the variable numbers. Your task is to compute the sum of all elements in this list and assign the result to the variable total. The total variable should be of type int. You are not allowed to use the built‐in sum() function — you must implement the summation manually (e.g. with a loop). Finally, print the result in the format:

python

Løsning

Switch to desktopBytt til skrivebordet for virkelighetspraksisFortsett der du er med et av alternativene nedenfor
Alt var klart?

Hvordan kan vi forbedre det?

Takk for tilbakemeldingene dine!

Seksjon 1. Kapittel 2

Spør AI

expand
ChatGPT

Spør om hva du vil, eller prøv ett av de foreslåtte spørsmålene for å starte chatten vår

book
With broken test

Here test broken

Oppgave

Swipe to start coding

You have a list of integers stored in the variable numbers. Your task is to compute the sum of all elements in this list and assign the result to the variable total. The total variable should be of type int. You are not allowed to use the built‐in sum() function — you must implement the summation manually (e.g. with a loop). Finally, print the result in the format:

python

Løsning

Switch to desktopBytt til skrivebordet for virkelighetspraksisFortsett der du er med et av alternativene nedenfor
Alt var klart?

Hvordan kan vi forbedre det?

Takk for tilbakemeldingene dine!

Seksjon 1. Kapittel 2
Switch to desktopBytt til skrivebordet for virkelighetspraksisFortsett der du er med et av alternativene nedenfor
Vi beklager at noe gikk galt. Hva skjedde?
some-alt