Skip to content

Instantly share code, notes, and snippets.

@tykurtz
tykurtz / grokking_to_leetcode.md
Last active May 1, 2024 22:47
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

@primaryobjects
primaryobjects / hotspot-keep-alive.ps1
Last active May 1, 2024 22:47
Script to Enable Windows 10 Mobile Hotspot Automatically After Reboot
# https://superuser.com/a/1434648
Add-Type -AssemblyName System.Runtime.WindowsRuntime
$asTaskGeneric = ([System.WindowsRuntimeSystemExtensions].GetMethods() | ? { $_.Name -eq 'AsTask' -and $_.GetParameters().Count -eq 1 -and $_.GetParameters()[0].ParameterType.Name -eq 'IAsyncOperation`1' })[0]
Function Await($WinRtTask, $ResultType) {
$asTask = $asTaskGeneric.MakeGenericMethod($ResultType)
$netTask = $asTask.Invoke($null, @($WinRtTask))
$netTask.Wait(-1) | Out-Null
$netTask.Result
@aymericbeaumet
aymericbeaumet / delete-likes-from-twitter.md
Last active May 1, 2024 22:40
[Recipe] Delete all your likes/favorites from Twitter

Ever wanted to delete all your likes/favorites from Twitter but only found broken/expensive tools? You are in the right place.

  1. Go to: https://twitter.com/{username}/likes
  2. Open the console and run the following JavaScript code:
setInterval(() => {
  for (const d of document.querySelectorAll('div[data-testid="unlike"]')) {
    d.click()
 }
@FantasyCheese
FantasyCheese / main.dart
Created September 18, 2020 11:57
Simplest MultiProvider Example
import 'dart:async';
import 'package:flutter/material.dart';
import 'package:provider/provider.dart';
void main() {
runApp(MultiProvider(
providers: [
ChangeNotifierProvider(create: (_) => Counter()),
ChangeNotifierProvider(create: (_) => Clock())
@iamamused
iamamused / Pinout_EPS32.txt
Created February 19, 2020 16:03
ESP32 Development Board Pinout Ascii Art
Unoffical ESP32 Development Board Pinout Ascii Art
For more information:
https://www.espressif.com/en/products/hardware/esp32/overview
https://lastminuteengineers.com/esp32-arduino-ide-tutorial/#esp32-development-board-pinout
@Nielk1
Nielk1 / ExtendInput.DataTools.DualSense.TriggerEffectGenerator.cs
Last active May 1, 2024 22:32
Factories for all DualSense trigger effects
/*
* MIT License
*
* Copyright (c) 2021-2022 John "Nielk1" Klein
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
@yuyasugano
yuyasugano / ema_backtesting.py
Created August 1, 2020 09:13
backtesting.py ema strategy
from backtesting import Strategy
from backtesting.lib import crossover
def EMA_Backtesting(values, n):
"""
Return exponential moving average of `values`, at
each step taking into account `n` previous values.
"""
close = pd.Series(values)
return talib.EMA(close, timeperiod=n)
@coolaj86
coolaj86 / MacOS-Icons.md
Last active May 1, 2024 22:18
MacOS Default Icons Locations

How to Find ANY Icon

  1. Open the application such that you see the icon on your screen.
  2. Open Activity Monitor
  3. Double click the name of the application (i.e. Finder or System Preferences)
  4. Select "Open Files and Ports"
  5. Copy the output to a file and then grep for .icns

Similarly you could run this command, but it may take several minutes to complete:

@roachhd
roachhd / README.md
Last active May 1, 2024 22:17
EMOJI cheatsheet ๐Ÿ˜›๐Ÿ˜ณ๐Ÿ˜—๐Ÿ˜“๐Ÿ™‰๐Ÿ˜ธ๐Ÿ™ˆ๐Ÿ™Š๐Ÿ˜ฝ๐Ÿ’€๐Ÿ’ข๐Ÿ’ฅโœจ๐Ÿ’๐Ÿ‘ซ๐Ÿ‘„๐Ÿ‘ƒ๐Ÿ‘€๐Ÿ‘›๐Ÿ‘›๐Ÿ—ผ๐Ÿ”ฎ๐Ÿ”ฎ๐ŸŽ„๐ŸŽ…๐Ÿ‘ป

EMOJI CHEAT SHEET

Emoji emoticons listed on this page are supported on Campfire, GitHub, Basecamp, Redbooth, Trac, Flowdock, Sprint.ly, Kandan, Textbox.io, Kippt, Redmine, JabbR, Trello, Hall, plug.dj, Qiita, Zendesk, Ruby China, Grove, Idobata, NodeBB Forums, Slack, Streamup, OrganisedMinds, Hackpad, Cryptbin, Kato, Reportedly, Cheerful Ghost, IRCCloud, Dashcube, MyVideoGameList, Subrosa, Sococo, Quip, And Bang, Bonusly, Discourse, Ello, and Twemoji Awesome. However some of the emoji codes are not super easy to remember, so here is a little cheat sheet. โœˆ Got flash enabled? Click the emoji code and it will be copied to your clipboard.

People

:bowtie: ๐Ÿ˜„