ACF costum date format [closed]

<?php 

/*
*  Create PHP DateTime object from Date Piker Value
*  this example expects the value to be saved in the format: yymmdd (JS) = Ymd (PHP)
*/

$format_in = 'Ymd'; // the format your value is saved in (set in the field options)
$format_out="d-m-Y"; // the format you want to end up with

$date = DateTime::createFromFormat($format_in, get_field('date_picker'));

echo $date->format( $format_out );