added a function that takes an input. also added a Makefile