<?php // your code goes here$date = new \Datetime('2021-01-02');var_dump($date);
Standard input is empty
object(DateTime)#1 (3) { ["date"]=> string(26) "2021-01-02 00:00:00.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(3) "UTC" }
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!