in_array(search, array, type) // third parameter is optional
$colours = ["Red", "Black", "White"]; if (in_array("Black", $colours)) echo "Match found!"; else echo "Match not found!"; // outputs: Match found!
Pro tip: use ```triple backticks around text``` to write in code fences