A simple ruby application for finding the nth prime.
More than anything, this is me working to improve my understanding of ruby & testing.
Specifically built to answer Problem 7 from Project Euler
git clone git@github.com:thewatts/primer.gitcd primerbundle install(needed for progress_bar)ruby bin/primershould do the trick, though I'm new at this thing.
- Keep them small
- Only a few lines
- If there is a lot going on -> too complicated
- Still kinda confused on this whole deal.
- Specifically why they used modules over regular classes...
- I used the same 'layout' for organizing/creating things as The RSPEC Book's codebreaker project
- Having a Rake file makes testing easier, instead of having to type the ruby testing commands.
- Write tests the same way I would test in the command line, makes it easier!
- even though this is a terminal app, intentional readability is very necessary to show what's clearly going on. without such, the app could be confusing.
- @jdtornow for helping me break down my original file
lib/primer/prime.rbinto smaller chunks & for giving me a 101 on testing! - @ernie for giving me perspective on naming conventions and evaluating true use case for the project - command line app vs what I have now (with the messages, outputs, etc)!
- @steveklabnik for sharing some code smells (ex: require_relative) and pointing me in the directino of some services, such as CodeClimate/TravisCI/Coveralls.io!