SLOWER VERSION (5 GFLOPS BUT TAKES CARE OF EDGES) 241 241 WORKS