There are two important files in this git repo:
tests/testthat/test-ninety_nine_beers.R
R/ninety_nine_beers.R
> renv::restore()
To generate the lyrics of 99 bottles of beer execute the command:
$ Rscript main99.R
...
1 bottle of beer on the wall, 1 bottle of beer
Take one down and pass it around, no more bottles of beer on the wall
No more bottles of beer on the wall, no more bottles of beer
Go to the store and buy some more, 99 bottles of beer on the wall
To generate the lyrics for a number of n bottles of beer (e.g., n=3
):
$ Rscript main_n.R 3
ℹ Loading ninetyNineBeers
The generated lyrics for n=3 are:
3 bottles of beer on the wall, 3 bottles of beer
Take one down and pass it around, 2 bottles of beer on the wall
2 bottles of beer on the wall, 2 bottles of beer
Take one down and pass it around, 1 bottle of beer on the wall
1 bottle of beer on the wall, 1 bottle of beer
Take one down and pass it around, no more bottles of beer on the wall
No more bottles of beer on the wall, no more bottles of beer
Go to the store and buy some more, 3 bottles of beer on the wall
> devtools::test()
ℹ Loading ninetyNineBeers
ℹ Testing ninetyNineBeers
✓ | F W S OK | Context
✓ | 7 | ninety_nine_beers
══ Results ════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════
[ FAIL 0 | WARN 0 | SKIP 0 | PASS 7 ]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.