first commit
implemented threads
added some examples