Skip to content

Instantly share code, notes, and snippets.

/*
*
* Correct Answer: 4259
* noun, verb
* 42, 59
* node Day2p2.js 0.09s user 0.08s system 81% cpu 0.211 total
*/
var intSet = [
1,
0,
/*
*
* Correct Answer:
* 5866663
* node Day2p1.js 0.06s user 0.08s system 94% cpu 0.149 total
*/
const intSet = [
1,
0,
0,
/*
* Wrong answers:
* 17946289, 24473910, 17946495, 8155726
*
* Correct Answer:
* 4892166
* node Day1p2.js 0.06s user 0.08s system 95% cpu 0.147 total
*/
var modules_mass = Array(
128167,
/***
*
* Ans: 3263354
* node Day1.js 0.09s user 0.03s system 84% cpu 0.147 total
*
*/
var modules = Array(
128167,
65779,
88190,
@samjaninf
samjaninf / .htaccess
Created December 5, 2019 03:51 — forked from seoagentur-hamburg/.htaccess
UPDATE 2019/07: Perfect .htaccess file for highspeed and security. You can use it for every WordPress-Website without problems. Highspeed and Security - testet on hundreds of Websites. If you are using a WordPress Multisite, change the last part of this file.
########################################################################
# OPTIMAL .htaccess FILE FOR SPEED AND SECURITY @Version 2019
# ----------------------------------------------------------------------
# @Author: Andreas Hecht
# @Author URI: https://andreas-hecht.com
# License: GNU General Public License v2 or later
# License URI: http://www.gnu.org/licenses/gpl-2.0.html
########################################################################
@samjaninf
samjaninf / gist:264892101edb63ed0b7bddfa44860d2c
Created October 23, 2019 21:09 — forked from vicalloy/gist:4603625
[coffeescript] maze generator
fmtTime = (t) ->
d = new Date(null);
d.setSeconds(t/1000);
return d.toTimeString().substr 3, 5
move = (obj, direction, step) ->
if !step?
step = 10
attr = 'left'
@samjaninf
samjaninf / webhook.py
Created October 23, 2019 21:09 — forked from vicalloy/webhook.py
Github event handler
from bottle import abort
from bottle import post
from bottle import request
from bottle import run
from subprocess import call
def handle_pull_request(o):
pass
@samjaninf
samjaninf / gist:79576c477cfad153e230695b2ac93747
Created October 23, 2019 21:07 — forked from vicalloy/gist:4593240
[python] maze generator
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
import random
try:
from tkinter import *
except ImportError:
from Tkinter import *
class Block(object):
@samjaninf
samjaninf / tmux.conf
Last active June 6, 2023 01:33
tmux config file
# remap prefix to Control + a
unbind C-b
set -g prefix C-a
#bind C-a send-prefix
# Screen Bindings
bind-key C-a last-window
# quick pane cycling
unbind ^A
version: '3'
networks:
front-external:
driver: overlay
external: true
volumes:
glpi_files: {}
glpi_mariadb: {}