Skip to content

Instantly share code, notes, and snippets.

View harryWonder's full-sized avatar
🇳🇬
I am that software developer that you cannot sideline. I am <harrywonder/>

Ilori stephen harryWonder

🇳🇬
I am that software developer that you cannot sideline. I am <harrywonder/>
View GitHub Profile
@harryWonder
harryWonder / staircase.js
Created June 14, 2022 20:51
The staircase algorithm with javascript.
/**
* Determine the number of stairs to print
* The default stair has to have at least 1 space from the left
* Other stairs should inherit the same syntax except the last one
*
* First thing I had to do was initalize an empty stairs.
* Create a loop based on the stairCaseLength Param.
* Initialize two indexes. (One to handle the loop from 0 - stairCaseLength)(i) and the other to (decrement the stairCaseLength)(j)
* For each case to be printed to the console, I had to use the .repeat method with (j - 1) to print the number of spaces the stairs(#)(i) should have. This would in turn make sure that the last stair to be printed has no spacing.
* The stairs denoted by (#) are also printed out using the repeat method and it takes the (i + 1) as a param.
@ankurk91
ankurk91 / laravel_horizon.md
Last active April 21, 2024 01:27
Laravel Horizon, redis-server, supervisord on Ubuntu server

Laravel Horizon, redis-server, supervisord on Ubuntu 20/22 server

Laravel 8+, Horizon 5.x, Redis 6+

Parepare application

  • Install and configure Laravel Horizon as instructed in docs
  • Make sure you can access the Horizon dashboard like - http://yourapp.com/horizon
  • For now; it should show status as inactive on horizon dashbaord

Install redis-server