Add wc.py
Replace rfind() with os.path.dirname()