Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<bits/stdc++.h>
- using namespace std;
- #define fast()(ios_base::sync_with_stdio(false),cin.tie(NULL));
- typedef long long ll;
- int main()
- {
- fast();
- ll t,c=1;
- cin>>t;
- while(t--)
- {
- ll n,x=0,i=0;
- cin>>n;
- while(i<n)
- {
- ll j;
- cin>>j;
- j*=n-i;
- x=max(x,j);
- i++;
- }
- cout<<"Case "<<c++<<": "<<x<<endl;
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment