Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Oppiskele Challenge: Reverse Words in a Sentence | Section
C# Loops Practice
Osio 1. Luku 16
single

single

bookChallenge: Reverse Words in a Sentence

Pyyhkäise näyttääksesi valikon

Tehtävä

Swipe to start coding

Write a function that reverses the order of words in a given sentence using a loop.

  • The function must split the input sentence into words.
  • The function must use a loop to reconstruct the sentence with the words in reverse order.
  • The function must return the reversed sentence as a single string.

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 1. Luku 16
single

single

Kysy tekoälyä

expand

Kysy tekoälyä

ChatGPT

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

some-alt