Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Oppiskele Challenge: Generate Multiples | Functions Returning Arrays & Refactoring Loops
Practice
Projects
Quizzes & Challenges
Quizzes
Challenges
/
C# Methods & Modular Thinking

bookChallenge: Generate Multiples

Tehtävä

Swipe to start coding

Write a method that returns an array of multiples of a given number up to a specified limit.

  • The method must return an array containing all multiples of number that are less than or equal to limit.
  • If number is zero or greater than limit, the method must return an empty array.
  • The array must contain the multiples in ascending order, starting from number up to the largest multiple not exceeding limit.

Ratkaisu

Oliko kaikki selvää?

Miten voimme parantaa sitä?

Kiitos palautteestasi!

Osio 2. Luku 2
single

single

Kysy tekoälyä

expand

Kysy tekoälyä

ChatGPT

Kysy mitä tahansa tai kokeile jotakin ehdotetuista kysymyksistä aloittaaksesi keskustelumme

close

bookChallenge: Generate Multiples

Pyyhkäise näyttääksesi valikon

Tehtävä

Swipe to start coding

Write a method that returns an array of multiples of a given number up to a specified limit.

  • The method must return an array containing all multiples of number that are less than or equal to limit.
  • If number is zero or greater than limit, the method must return an empty array.
  • The array must contain the multiples in ascending order, starting from number up to the largest multiple not exceeding limit.

Ratkaisu

Switch to desktopVaihda työpöytään todellista harjoitusta vartenJatka siitä, missä olet käyttämällä jotakin alla olevista vaihtoehdoista
Oliko kaikki selvää?

Miten voimme parantaa sitä?

Kiitos palautteestasi!

Osio 2. Luku 2
single

single

some-alt