Skip to content

itsmeolivia/bits-required

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

bits required?

How many bits do we need to represent values up to x? For example, to represent values up to 10, we need 4 bits. To represent up to 169, we need 8 bits.

I wanted to try implementing this in various programming languages as an exercise. The program reads a number from the command line (in argv) and prints the number of required bits; that's it!

About

a little experiment with various programming languages

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published