Wrote the basic program