Explanation: Users: User 1, User2 , User 3 and User 4 You can delete all users whether a license is assigned directly or via inheritance from a group membership. Groups: Group 2 and Group 4 Groups with active license assignments cannot be deleted. You get an error. https://techcommunity.microsoft.com/t5/microsoft-365-admin-center/reclaiming-licenses-from-deleted-users/m-p/116488