Codewars Javascript - Bit Counting - SOLVED IN 3 EASY STEPS!

Publié le: 16 août 2017
sur la chaîne: Code Noob
2,037
23

In this video I'll be taking you step by step in detail how I solved the "Bit Counting" challenge in 3 easy steps using javascript on codewars .com.

This is a great video to practice using the replace function as well as learning about the radix parameter and how to change a string into an integer.

The steps I took to complete this challenge are as follows(I go into more detail in the video):

STEP 1
Convert the number to binary.

STEP 2
Remove zeros from the string

STEP 3
Iterate through the digits and add them up.


Useful links:

Radix: https://goo.gl/y6GWRe;

parseInt: https://goo.gl/Ypd6SP


Sur cette page du site, vous pouvez voir la vidéo en ligne Codewars Javascript - Bit Counting - SOLVED IN 3 EASY STEPS! durée heure minute seconde en bonne qualité , qui a été Téléchargé par l'utilisateur Code Noob 16 août 2017, Partagez le lien avec vos amis et connaissances, sur youtube cette vidéo a déjà été regardée 2,037 fois et il a aimé 23 téléspectateurs. Bon visionnage!