/* package whatever; // don't place package name! */
import java.util.*;
import java.lang.*;
import java.io.*;
import java.util.Date;
import java.text.SimpleDateFormat;
/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
{
String data1
= "22-07-2017 00:00:00 +0100"; String data2
= "22-07-2017 18:57:17 +0100";
Date d1
= formato.
parse(data1
); Date d2
= formato.
parse(data2
);
System.
out.
println(d1.
compareTo(d2
)); }
}
LyogcGFja2FnZSB3aGF0ZXZlcjsgLy8gZG9uJ3QgcGxhY2UgcGFja2FnZSBuYW1lISAqLwoKaW1wb3J0IGphdmEudXRpbC4qOwppbXBvcnQgamF2YS5sYW5nLio7CmltcG9ydCBqYXZhLmlvLio7CmltcG9ydCBqYXZhLnV0aWwuRGF0ZTsKaW1wb3J0IGphdmEudGV4dC5TaW1wbGVEYXRlRm9ybWF0OwoKLyogTmFtZSBvZiB0aGUgY2xhc3MgaGFzIHRvIGJlICJNYWluIiBvbmx5IGlmIHRoZSBjbGFzcyBpcyBwdWJsaWMuICovCmNsYXNzIElkZW9uZQp7CglwdWJsaWMgc3RhdGljIHZvaWQgbWFpbiAoU3RyaW5nW10gYXJncykgdGhyb3dzIGphdmEubGFuZy5FeGNlcHRpb24KCXsKCQlTaW1wbGVEYXRlRm9ybWF0IGZvcm1hdG8gPSBuZXcgU2ltcGxlRGF0ZUZvcm1hdCAoImRkLU1NLXl5eXkgSEg6bW06c3MgWiIpOwoJCVN0cmluZyBkYXRhMSA9ICIyMi0wNy0yMDE3IDAwOjAwOjAwICswMTAwIjsKCQlTdHJpbmcgZGF0YTIgPSAiMjItMDctMjAxNyAxODo1NzoxNyArMDEwMCI7CgkJCgkJRGF0ZSBkMSA9IGZvcm1hdG8ucGFyc2UoZGF0YTEpOwoJCURhdGUgZDIgPSBmb3JtYXRvLnBhcnNlKGRhdGEyKTsKCgkJU3lzdGVtLm91dC5wcmludGxuKGQxLmNvbXBhcmVUbyhkMikpOwoJfQp9