<?php 
function gettingmarried($women, $men) {

$count=count($women); //count-counts the number of women.

// '!=' -If not equal.
if ($women != count($men)) {
echo "I don't have all pairs";
}

//array_combine-Pairs the data of the first element with the second.
return  array_combine($women, $men);
}

print_r(gettingmarried(["elene","mariami"], ["dato", "vano"]));
by Gvanca Gharibashvili
2 years ago
PHP
Object Oriented PHP Tutorial
0
Pro tip: use ```triple backticks around text``` to write in code fences