<?php
$country_codes = array('UK','IRL');
$country_list = array(
'ALB' => 'Albania',
'AND' => 'Andorra',
'ARM' => 'Armenia',
'AUT' => 'Austria',
'AZE' => 'Azerbaijan',
'BLR' => 'Belarus',
'BEL' => 'Belgium',
'BIH' => 'Bosnia and Herzegovina',
'BGR' => 'Bulgaria',
'HRV' => 'Croatia',
'CYP' => 'Cyprus',
'CZE' => 'Czech Republic',
'DNK' => 'Denmark',
'EST' => 'Estonia',
'FIN' => 'Finland',
'FRA' => 'France',
'GEO' => 'Georgia',
'DEU' => 'Germany',
'GRC' => 'Greece',
'HUN' => 'Hungary',
'ISL' => 'Iceland',
'IRL' => 'Ireland',
'ITA' => 'Italy',
'KAZ' => 'Kazakhstan',
'RKS' => 'Kosovo',
'LVA' => 'Latvia',
'LIE' => 'Liechtenstein',
'LTU' => 'Lithuania',
'LUX' => 'Luxembourg',
'MLT' => 'Malta',
'MDA' => 'Moldova',
'MCO' => 'Monaco',
'MNE' => 'Montenegro',
'NLD' => 'Netherlands',
'MKD' => 'North Macedonia',
'NOR' => 'Norway',
'POL' => 'Poland',
'PRT' => 'Portugal',
'ROU' => 'Romania',
'RUS' => 'Russia',
'SMR' => 'San Marino',
'SRB' => 'Serbia',
'SVK' => 'Slovakia',
'SVN' => 'Slovenia',
'ESP' => 'Spain',
'SWE' => 'Sweden',
'CHE' => 'Switzerland',
'TUR' => 'Turkey',
'UKR' => 'Ukraine',
'UK' => 'UK',
);
$filtered_countries = array_intersect_key($country_list, array_flip($country_codes));
print_r($filtered_countries);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename: /in/EvvQu
function name: (null)
number of ops: 14
compiled vars: !0 = $country_codes, !1 = $country_list, !2 = $filtered_countries
line #* E I O op fetch ext return operands
-------------------------------------------------------------------------------------
3 0 E > ASSIGN !0, <array>
5 1 ASSIGN !1, <array>
58 2 INIT_FCALL 'array_intersect_key'
3 SEND_VAR !1
4 INIT_FCALL 'array_flip'
5 SEND_VAR !0
6 DO_ICALL $5
7 SEND_VAR $5
8 DO_ICALL $6
9 ASSIGN !2, $6
59 10 INIT_FCALL 'print_r'
11 SEND_VAR !2
12 DO_ICALL
13 > RETURN 1
Generated using Vulcan Logic Dumper, using php 8.0.0
preferences:
148.34 ms | 1394 KiB | 19 Q