Skip to content

Instantly share code, notes, and snippets.

View lukKowalski's full-sized avatar
🙉
OMG Look at that code!

Łukasz Kowalski lukKowalski

🙉
OMG Look at that code!
View GitHub Profile
@lukKowalski
lukKowalski / generujTabliczke_xD.js
Last active March 16, 2020 21:21
Generuje tabliczkę mnożenia/dzielenia do 50, po 18 w słupku. Wymagany node
#! /usr/bin/env node
//Generuje tabliczkę mnozenia/dzielenia w dwoch kolumnach, do 50, po 18 w slupku
//Wymagany: node
//uruchomienie: ./generujTabliczke_xD.js >> tabliczka (wrzuci tabliczke do pliku "tabliczka")
// 2 * 9 = ___ 16 : 2 = ___
// 9 * 1 = ___ 35 : 7 = ___
// 5 * 6 = ___ 30 : 3 = ___
// 7 * 4 = ___ 5 : 5 = ___
// 9 * 6 = ___ 45 : 5 = ___
const int lamp_0_0 = 5;
const int lamp_0_1 = 6;
const int lamp_0_2 = 7;
const int lamp_0_3 = 8;
const int lamp_0_4 = 9;
const int lamp_0_5 = 10;
const int lamp_1_0 = 11;
const int lamp_1_1 = 12;
const int sensor0 = 2;
const useControlledEffect = (callback, dependenciesArray) => {
const controlRef = useRef(false);
const stopFunc = () => {
controlRef.current = true;
};
const wrappedCallback = (params = []) => {
callback(stopFunc, controlRef.current, ...params);
};