WooCommerce multiple custom fields code

Not in stackoverflow nor stackexchange can`t answer my question. I dont know maybe they just can edit my writing dictation!. Anyway after searching in php courses my code is this now and works correctly:

<?php
$custom_field_type = get_post_meta($post->ID, '_custom_field_type', true);
$custom_field_type = array_filter($custom_field_type, 'strlen');
if (count($custom_field_type)) {
        echo '<div id="vijegiha">';
          echo '<h3 id="vijegih3">ویژگی های کلیدی</h3>';
            echo '<ul>';
                foreach($custom_field_type as $vijegi)
                if (!empty( $vijegi )) {
                     echo '<li>'.$vijegi.'</li>';}
            echo '</ul>';
        echo '</div>';
}else{} ?>