Skip to content

Instantly share code, notes, and snippets.

@tykurtz
tykurtz / grokking_to_leetcode.md
Last active April 20, 2024 14:40
Grokking the coding interview equivalent leetcode problems

GROKKING NOTES

I liked the way Grokking the coding interview organized problems into learnable patterns. However, the course is expensive and the majority of the time the problems are copy-pasted from leetcode. As the explanations on leetcode are usually just as good, the course really boils down to being a glorified curated list of leetcode problems.

So below I made a list of leetcode problems that are as close to grokking problems as possible.

Pattern: Sliding Window

@cdsousa
cdsousa / blender_julia.py
Last active April 20, 2024 14:40
Julia inside Python inside Blender
bl_info = {
"name": "Julia console",
"blender": (4, 0, 0),
"category": "Scripting",
}
def register():
# install JuliaCall within Blender's Python environment (if not already installed)
import importlib
if importlib.util.find_spec('juliacall') is None:

SHORTCUTS

Key/Command Description
Tab Auto-complete files and folder names
Ctrl + A Go to the beginning of the line you are currently typing on
Ctrl + E Go to the end of the line you are currently typing on
Ctrl + U Clear the line before the cursor
Ctrl + K Clear the line after the cursor
Ctrl + W Delete the word before the cursor
Ctrl + T Swap the last two characters before the cursor
@alejandro-martin
alejandro-martin / multiple-ssh-keys-git.adoc
Last active April 20, 2024 14:36
Configure multiple SSH Keys for Git

Use Multiple SSH Keys for Git host websites (Github, Gitlab)

This is guide about how to configure multiple SSH keys for some Git host websites such as Github, Gitlab, among others.

Creating SSH keys

  1. Create SSH directory:

@nunomcruz
nunomcruz / advanced_conf-telnet.md
Created February 21, 2021 00:08 — forked from Anime4000/advanced_conf-telnet.md
XPON SFP ONU (V2801F), XPON STICK ONU (TWCGPON657), RTL8672, RTL9601C1

Clearing Up

  • Original author have abandoned DFP-34G-2C2 (ZTE) and moved to Realtek
  • Take not that V2801F using Realtek SoC RTL9601C1, not RTL8672
  • RTL8672 is ADSL Modem, /proc/cpuinfo reported wrong.
  • RTL9601C1 consider stable, active development and large user base

Telnet Command:

Username: admin
@robertgonzales
robertgonzales / Frame.js
Created December 12, 2017 03:03
Use React portals to render inside shadow dom and iframes
class Frame extends Component {
componentDidMount() {
this.iframeHead = this.node.contentDocument.head
this.iframeRoot = this.node.contentDocument.body
this.forceUpdate()
}
render() {
const { children, head, ...rest } = this.props
return (
@tanaikech
tanaikech / submit.md
Created May 20, 2018 04:44
Create Folder Tree of Google Drive using Node.js

Create Folder Tree of Google Drive using Node.js

This is a sample script for retrieving a folder tree using Node.js. In this sample, you can set the top of folder for the folder tree. In generally, the folder tree is created by retrieving folders from the top folder in order. For example, when Google Apps Script is used, the script becomes like this. But when Drive API is used for this situation, if there are a lot of folders in the top folder, a lot of APIs are required to be called. So in this sample, I have tried to create the folder tree by a small number of API calls as possible.

In this sample, in order to be easy to understand the flow, I used Quickstart for Node.js. When you use this sample script, at first, please check the document of Quickstart. And I confirmed that this sample worked at googleapis v30.0.0.

Flow :

  1. Retrieve all folders in Google Drive.
@onsails
onsails / cancelot.sh
Created May 17, 2020 00:54 — forked from siberex/cancelot.sh
Provides automation for cancelling previous ongoing Cloud Builds for the same branch/trigger
#!/usr/bin/env bash
# https://gist.github.com/siberex/bb0540b208019382d08732cc6dd59007
# Provides automation for cancelling Cloud Builds
# Use as a first step to cancel previous builds currently in progress or queued for the same branch name and trigger id.
# Similar to: https://github.com/GoogleCloudPlatform/cloud-builders-community/tree/master/cancelot
# Usage: cancelot.sh --current_build_id $BUILD_ID --branch_name $BRANCH_NAME --same_trigger_only
# Usage within Cloud Build step:
# steps:
@nagavinodcse
nagavinodcse / alpinejs-carousel-using-swiper-tailwindcss.markdown
Created December 25, 2020 15:59
AlpineJS Carousel using Swiper + Tailwindcss