Skip to content

Instantly share code, notes, and snippets.

@ajfg93
ajfg93 / waitForKeyElements.js
Created May 9, 2021 14:22 — forked from BrockA/waitForKeyElements.js
A utility function, for Greasemonkey scripts, that detects and handles AJAXed content.
/*--- waitForKeyElements(): A utility function, for Greasemonkey scripts,
that detects and handles AJAXed content.
Usage example:
waitForKeyElements (
"div.comments"
, commentCallbackFunction
);
@ajfg93
ajfg93 / main.cpp
Last active December 25, 2018 04:07
MergeSortArrayAccessCountTrial
#include <iostream>
#include <vector>
#include <random>
#include <cmath>
#include "mergesortTop.h"
#include "mergesortUp.h"
using namespace std;
random_device rd;
mt19937 e(rd());
def zuhe(sz, a_list, index):
if not index <= len(sz):
print("FUCK YOURSELF")
return
if index == 1:
for x in sz:
new_array = a_list[:]
new_array.append(x)
print(new_array)
def qpl(sz, index):
if len(sz) == index:
print(sz)
return
else:
for x in range(index, len(sz)):
if x == 0:
new_array = sz[:]
qpl(new_array, index + 1)
else: