One Script to Rule them All (The Black Hat tutorial)
UPDATE: Please note that I just started play BitBurner today 10/30/2022. My son showed it to me and I love it. And I am, grateful for the tutorials.
This code comes from the tutorial by The Black Hat on YouTube @ https://www.youtube.com/watch?v=nePsChf_Ifk
• Function Main() diverts all of the server's available threads to the most valuable command.
• Main calls upon three scripts to weaken, grow and hack: 'bin.wk.js, bin.gr.js, and bin.hk.js'.
• Function ServerList() returns an array of servers to hack dynamically.
• Function TreadCount() converts hostname & scriptRam into a number of threads that represents the server's total capacity.