added candy solution