added magic box solution