##Steps to follow :
Clone the project on local git repiository And add below jars in classpath:
1.junit-4.13
2.hamcrest-core-1.3
Run StartFan.java class.
##Assumption :
The initial state of Fan is Off State/Speed Zero We can only reverse the cord when atlease once fan is switched on. (moved from off to some other state).