php nested ternary operator
// The below statement is an exaple of the nested ternary operator in PHP
echo ($row["position"] != "NA") ? $row["position"] :
(($row["current_degree"] != "NA") ? $row["current_degree"] :
$row["qualification"]);
// The equivalent if else structure is given below
if ($row["position"] != "NA"){
echo $row["position"];
} elseif($row["current_degree"] != "NA"){
echo $row["current_degree"];
} else{
echo $row["qualification"];
}