Skip to content

Instantly share code, notes, and snippets.

View Eghizio's full-sized avatar
😎
Full-Stack Developer

Jakub Wąsik Eghizio

😎
Full-Stack Developer
View GitHub Profile
@Eghizio
Eghizio / pokemons.ts
Created November 23, 2023 15:34
Pokemon static data
export const pokemons = [
{
"id": 1,
"name": "bulbasaur",
"types": [
"grass",
"poison"
],
"previewImageUrl": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/dream-world/1.svg",
"imageUrls": [
/*
(1) – algorithmic task
Task:
Write a function that receives two sequences: A and B of integers and returns one sequence C.
Sequence C should contain all elements from sequence A (maintaining the order) except those, that are present in sequence B p times, where p is a prime number.
Example:
A=[2,3,9,2,5,1,3,7,10]
B=[2,1,3,4,3,10,6,6,1,7,10,10,10]
C=[2,9,2,5,7,10]
@Eghizio
Eghizio / generateID.ts
Last active January 3, 2022 01:06
Generate random* (not really) string ID
// i like to use it when mocking things
const generateID = () => '_' + Math.random().toString(36).substring(2, 9);
@Eghizio
Eghizio / image-scraper.js
Created January 2, 2021 01:48
Simple image scraper Node.js example
const fetch = require("node-fetch");
const cheerio = require("cheerio");
const LABEL = "TIMER";
console.time(LABEL);
const URL = "https://demotywatory.pl/losuj";
const query = "img.demot";
const images = [];