Removed header files in examples (Spark IDE ignores them) and fixed the code