Greedy herustic is implemented, but does it work?
moved function to main which is more logical
fixed
compiles but still not correct