How to Hide the "Visitor Counter Options" Admin Menu

function plt_hide_mechanic_visitor_counter_menus() {
	//Hide the "Settings → Visitor Counter Options" menu.
	remove_submenu_page('options-general.php', 'plugin_statsmechanic_menu');
}

add_action('admin_menu', 'plt_hide_mechanic_visitor_counter_menus', 11);

Where do I put this code?