Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
    Kiki
    @kststudio
    Bonfire: Find the Longest Word in a String
    CamperBot
    @camperbot

    :fire:Bonfire: Find the Longest Word in a String :link:

    function findLongestWord(str) {
      return str.length;
    }
    
    findLongestWord('The quick brown fox jumped over the lazy dog');

    Return the length of the longest word in the provided sentence.

    more info:  bf details | bf links | hint

    Kiki
    @kststudio
    bf details
    CamperBot
    @camperbot

    :fire:Bonfire: Reverse a String :link:

    function reverseString(str) {
      return str;
    }
    
    reverseString('hello');
    Reverse the provided string.
    You may need to turn the string into an array before you can reverse it.
    Your result must be a string.
    Remember to use RSAP if you get stuck. Try to pair program. Write your own code.
    links:
    Vinamra
    @iambali
    hint
    CamperBot
    @camperbot

    hint [1/7]

    ## :construction: After this are possible spoiler hints.

    Make sure you've tried to hard to solve it yourself before proceeding. :construction:

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Sahil Bloch
    @sbilogic
    hint
    CamperBot
    @camperbot

    hint [2/7]

    # Problem Explanation:

    You need to take the string and reverse it so if you had originally 'hello', it will turn into 'olleh'. Because you will need to split it, you will be working with Arrays too.

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Sahil Bloch
    @sbilogic
    hint
    CamperBot
    @camperbot

    hint [3/7]

    Hint: 1

    • You should split the string by characters.

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Carolyn Leavitt
    @HarmonyOaks
    hint
    CamperBot
    @camperbot

    hint [1/7]

    ## :construction: After this are possible spoiler hints.

    Make sure you've tried to hard to solve it yourself before proceeding. :construction:

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Sarah Strange
    @strange1120
    @camperbot hint
    Norman Dela Cruz
    @dcnr
    hint
    CamperBot
    @camperbot

    hint [1/7]

    ## :construction: After this are possible spoiler hints.

    Make sure you've tried to hard to solve it yourself before proceeding. :construction:

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Norman Dela Cruz
    @dcnr
    bonfire reverse a string
    CamperBot
    @camperbot

    :fire:Bonfire: Reverse a String :link:

    function reverseString(str) {
      return str;
    }
    
    reverseString('hello');

    Reverse the provided string.

    more info:  bf details | bf links | hint

    Norman Dela Cruz
    @dcnr
    hint
    CamperBot
    @camperbot

    hint [2/7]

    # Problem Explanation:

    You need to take the string and reverse it so if you had originally 'hello', it will turn into 'olleh'. Because you will need to split it, you will be working with Arrays too.

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Norman Dela Cruz
    @dcnr
    hint
    CamperBot
    @camperbot

    hint [3/7]

    Hint: 1

    • You should split the string by characters.

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Norman Dela Cruz
    @dcnr
    hint
    CamperBot
    @camperbot

    hint [4/7]

    Hint: 2

    • Find out about the built in function to reverse a string.

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Norman Dela Cruz
    @dcnr
    hint
    CamperBot
    @camperbot

    hint [5/7]

    Hint: 3

    • Once you have split and reversed, do not forget to join them back into one string.

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Norman Dela Cruz
    @dcnr
    hint
    CamperBot
    @camperbot

    hint [6/7]

    Spoiler Alert!

    687474703a2f2f7777772e796f75726472756d2e636f6d2f796f75726472756d2f696d616765732f323030372f31302f31302f7265645f7761726e696e675f7369676e5f322e676966.gif

    Solution ahead!

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Norman Dela Cruz
    @dcnr
    hint
    CamperBot
    @camperbot

    hint [7/7]

    Code Solution:

    function reverseString(str) {
      var strReverse = str.split('').reverse().join('');
      return strReverse;
    }

    Code Explanation:

    This is a straightforward code. We create a variable that will hold the string split by characters, and then reversed and put back together.

    Credits:

    If you found this page useful, you can give thanks by copying and pasting this on the main chat: Thanks @Rafase282 for your help with Bonfire: Reverse a String

    NOTE: Please add your username only if you have added any relevant main contents to the wiki page. (Please don't remove any existing usernames.)

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Norman Dela Cruz
    @dcnr
    WELL I'LL BE DAMNED
    verseunl
    @verseunl
    hint
    CamperBot
    @camperbot

    hint [1/7]

    ## :construction: After this are possible spoiler hints.

    Make sure you've tried to hard to solve it yourself before proceeding. :construction:

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    verseunl
    @verseunl
    hint
    CamperBot
    @camperbot

    hint [2/7]

    # Problem Explanation:

    We need to take the string and reverse it, so if it originally reads 'hello', it will now read 'olleh'. We will need to split the string, and therefore we will be working with Arrays as well.

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Sarah
    @gingersnapp
    hint
    CamperBot
    @camperbot

    hint [1/1]

    ## :construction: After this are possible spoiler hints.

    Make sure you've tried to hard to solve it yourself before proceeding. :construction:

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    Sarah
    @gingersnapp
    hint
    CamperBot
    @camperbot
    These hints depend on people like you! Please add to this :point_right: Bonfire's Wiki Hints Page
    PathGeek
    @pathgeek
    hint
    CamperBot
    @camperbot

    hint [1/1]

    ## :construction: After this are possible spoiler hints.

    Make sure you've tried to hard to solve it yourself before proceeding. :construction:

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    ientropic
    @ientropic
    hint
    CamperBot
    @camperbot

    hint [1/1]

    ## :construction: After this are possible spoiler hints.

    Make sure you've tried to hard to solve it yourself before proceeding. :construction:

    type hint for next hint :pencil: [Contribute at the FCC Wiki]

    ientropic
    @ientropic
    hint
    CamperBot
    @camperbot
    These hints depend on people like you! Please add to this :point_right: Bonfire's Wiki Hints Page
    Veronica Eulenberg
    @HappyViki
    How do I save my notification settings on here? It keeps on reverting!
    Bhavya Kamboj
    @bhavyakamboj
    hint
    Atmosphere ASMR
    @Atmosphere_ASMR_twitter
    hint
    hint
    Tiffany
    @tiffanyls
    hint
    Justin-Godfrey
    @Justin-Godfrey
    hint