add exists() func
add examples for exists()
Merge pull request #222 from doochik/patch-5

add exists() func