/* package whatever; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

import java.time.* ;
import java.time.format.* ;

/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
	public static void main (String[] args) throws java.lang.Exception
	{
		try {
            LocalDate ld = LocalDate.parse( "2021-02-29" ) ;
            System.out.println( ld ) ;
        } catch ( DateTimeParseException e ) {
            // … handle invalid input
            System.out.println( "Faulty input" ) ;
        }
	}
}