Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Lernen Challenge: Array Loops | Arrays
Practice
Projects
Quizzes & Challenges
Quizzes
Challenges
/
C# Grundlagen

bookChallenge: Array Loops

Aufgabe

Swipe to start coding

Your task is to calculate the total sales for a set of days using a method.

  • Create a method CalculateTotalSales that:
    • Accepts an array of double values representing daily sales.
    • Uses a for loop to iterate through the array.
    • Calculates the total sum of all sales.
    • Returns the total as a double.

Lösung

War alles klar?

Wie können wir es verbessern?

Danke für Ihr Feedback!

Abschnitt 5. Kapitel 6
single

single

Fragen Sie AI

expand

Fragen Sie AI

ChatGPT

Fragen Sie alles oder probieren Sie eine der vorgeschlagenen Fragen, um unser Gespräch zu beginnen

close

bookChallenge: Array Loops

Swipe um das Menü anzuzeigen

Aufgabe

Swipe to start coding

Your task is to calculate the total sales for a set of days using a method.

  • Create a method CalculateTotalSales that:
    • Accepts an array of double values representing daily sales.
    • Uses a for loop to iterate through the array.
    • Calculates the total sum of all sales.
    • Returns the total as a double.

Lösung

Switch to desktopWechseln Sie zum Desktop, um in der realen Welt zu übenFahren Sie dort fort, wo Sie sind, indem Sie eine der folgenden Optionen verwenden
War alles klar?

Wie können wir es verbessern?

Danke für Ihr Feedback!

Abschnitt 5. Kapitel 6
single

single

some-alt