added proof of work code