From 9a37b5f59acab819bf6bccb52f8dcc40805ef303 Mon Sep 17 00:00:00 2001 From: ShazidMahsrafi Date: Thu, 31 Aug 2023 00:12:14 +0600 Subject: [PATCH] initial commit --- 492B Vanya and Lanterns/492B.cpp | 59 ++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 492B Vanya and Lanterns/492B.cpp diff --git a/492B Vanya and Lanterns/492B.cpp b/492B Vanya and Lanterns/492B.cpp new file mode 100644 index 0000000..830790e --- /dev/null +++ b/492B Vanya and Lanterns/492B.cpp @@ -0,0 +1,59 @@ +#include +using namespace std; + +#define ll long long +#define ul unsigned long long +#define pb push_back +#define ss second +#define ff first +#define fr(m) for(int i=0; i=0; --i) +#define nl '\n' +#define yes cout<<"YES"<>n>>l; + vectorlamps(n); + fr(n) + cin>>lamps[i]; + int mx=0; + sort(all(lamps)); + fro(n) + { + int x=lamps[i]-lamps[i-1]; + mx=max(x,mx); + } + cout<> TC; + while (TC--) solve(); +} \ No newline at end of file