Skip to content

Instantly share code, notes, and snippets.

View yelhady87's full-sized avatar

Yahia Ahmad yelhady87

  • Cairo, Egypt
  • 18:06 (UTC +02:00)
View GitHub Profile

Oh my zsh.

Install with curl

sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"

Enabling Plugins (zsh-autosuggestions & zsh-syntax-highlighting)

  • Download zsh-autosuggestions by
@yelhady87
yelhady87 / makecsv.py
Created October 5, 2020 16:10 — forked from AlanHohn/makecsv.py
Generate a random CSV in Python
#!/usr/bin/python
import csv
import random
records=9000000
print("Making %d records\n" % records)
fieldnames=['id','name','age','city']
writer = csv.DictWriter(open("people.csv", "w"), fieldnames=fieldnames)
@yelhady87
yelhady87 / PBQvsThreadPool.java
Created July 16, 2018 17:02 — forked from coderplay/PBQvsThreadPool.java
Using PriorityBlockingQueue in thread pool
import java.util.concurrent.Callable;
import java.util.concurrent.Future;
import java.util.concurrent.FutureTask;
import java.util.concurrent.PriorityBlockingQueue;
import java.util.concurrent.RejectedExecutionHandler;
import java.util.concurrent.RunnableFuture;
import java.util.concurrent.ThreadFactory;
import java.util.concurrent.ThreadPoolExecutor;
import java.util.concurrent.TimeUnit;