Graph problem