Skip to content

Instantly share code, notes, and snippets.

View Cheejyg's full-sized avatar
🏠
Working from home

Cheejyg Cheejyg

🏠
Working from home
View GitHub Profile
/*
* robot.js
*
* You'll need three keys in order to unlock the
* Algorithm: the red key, the green key, and the
* blue key. Unfortunately, all three of them are
* behind human-proof barriers.
*
* The plan is simple: reprogram the maintenance
* robots to grab the key and bring it through
import json
inputFilename = input("File: ")
with open(inputFilename, "rt") as input_file:
inputs = json.load(input_file)
source = ""
for x in range(len(inputs["cells"])):
for string in inputs["cells"][x]["source"]:
function getMultiple_FILES() {
$_FILE = array();
foreach($_FILES as $name => $file) {
foreach($file as $property => $keys) {
foreach($keys as $key => $value) {
$_FILE[$name][$key][$property] = $value;
}
}
}
return $_FILE;
@Cheejyg
Cheejyg / gist:a1698dde4848949ae84b7ce60c8cc396
Created December 16, 2021 05:12
Photoshop: Black alpha background to transparent image
1. Duplicate layer
2. With the upper layer selected, Image > Adjustments > Black & White > Preset: Lighter > Ok
3. Select All > Cut
4. Select lower layer
5. Add layer mask
6. Alt + Click layer mask
7. Paste
8. Right Click layer mask > Apply Layer Mask