This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | // POST.js v0.4 | |
| // A power-on self test for the player's hacking skill | |
| // | |
| // I am so sorry. | |
| // Written by jeek | |
| let FILENAME = "/POST.js"; | |
| // Ram Dodging | |
| export async function Do(ns, command, ...args) { | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | import { NS, Player, Server, ResetInfo } from "@ns"; | |
| let gangMemberNames: string[] = [ | |
| [ | |
| "Aries", | |
| "Taurus", | |
| "Gemini", | |
| "Cancer", | |
| "Leo", | |
| "Virgo", | 
      
      Loading
      
  Sorry, something went wrong. Reload?
      Sorry, we cannot display this file.
      Sorry, this file is invalid so it cannot be displayed.
      
    
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | // Reassigns your employees to the jobs they're best suited for, while maintaining the same number of employees in each position. | |
| class Employee { | |
| constructor (ns, division, city, name) { | |
| this.ns = ns; | |
| this.division = division; | |
| this.city = city; | |
| this.name = name; | |
| } | |
| get int() { | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | // packitin.js by jeek | |
| // death to the Zoë cult (not Zoë herself, though, she's cool) | |
| let mults = [ | |
| [.30, .20, .72, .30], // 0 - Agriculture | |
| [.20, .20, .25, .25], // 1 - Chemical | |
| [.19, .00, .20, .36], // 2 - Computer | |
| [.30, .00, .65, .05], // 3 - Energy | |
| [.20, .35, .50, .15], // 4 - Fishing | |
| [.25, .15, .05, .30], // 5 - Food | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | let GANG = "Slum Snakes"; | |
| let WANTED_THRESHOLD = 10; // If your wanted level is higher than this and your penalty is greater than (1-WANTED_PENALTY_THRESHOLD).... | |
| let WANTED_PENALTY_THRESHOLD = .9; // ... then do vigilante stuff. | |
| let TRAFFICK_CHANCE = .8; // Odds of arms trafficking vs terrorism when there is no Formulas.exe | |
| let REP_CHECK = 1.1; // Don't ascend anyone with over 1.1x the average rep of the group. | |
| let MINIMUM_RESPECT = 0; // Don't start ascension until the average respect is at least this. | |
| let CLASH_TARGET = .5; // Don't go to war until you have this much of a chance against all remaining gangs. | |
| let ASC = 1.06; | |
| import { createSidebarItem } from "/jeekOS.js" | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | let VERSION = "0.0"; | |
| let toasty = false; | |
| let POST_INSTALL_SCRIPT = '/jeek/start.js'; | |
| let WORLDS = { | |
| 1: "Source Genesis", | |
| 2: "Rise of the Underworld", | |
| 3: "Corporatocracy", | |
| 4: "The Singularity", | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | from copy import deepcopy as copy | |
| from heapq import heappop, heappush | |
| pieces = [ | |
| [[[ 0, 0, 1, 0 ], | |
| [ 1, 1, 1, 0 ], | |
| [ 1, 0 ,0 ,0 ], | |
| [ 0, 0, 0, 0 ]]], | |
| [[[ 1, 0, 1, 0], | |
| [ 1, 1, 1, 0], | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | all: real | |
| real: | |
| python3 euler.py | |
| test: | |
| python3 -munittest -v euler.py | |
| clean: | |
| rm -rf *~ __pycache__ | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | ignore = [10 ** j for j in xrange(100)] | |
| i = 10 | |
| while True: | |
| if i not in ignore: | |
| for j in xrange(1, len(str(i))): | |
| a, b = int(str(i)[:j]), int(str(i)[j:]) | |
| for power in xrange(1, 11): | |
| c = a ** power + b ** power | |
| for k in xrange(1, len(str(c))): | 
NewerOlder