Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
march long ques 4
#include<iostream> #include<bits/stdc++.h> #include <cmath> using namespace std; int main() { long long int t,n,k,m; ios_base::sync_with_stdio(false); cin.tie(NULL); cin >> t; while(t--) { cin >> n >> k; int a[n]; vector <int> temp; for(int i=0;i<n;++i){ cin >> a[i]; } for(int p=0;p<n;++p){ for(int i=0;i<n-p;++i){ vector <int> temp; map <int,int> mymap; for(int j=p;j<i+p+1;++j){ temp.push_back(a[j]); mymap[a[j]]++; } m=ceil(((float)k)/(i+1)); cout<<m<<" "; } } } }
run
|
edit
|
history
|
help
0
error
Dar
ISPrime
Count squares
on_off
ConversionOperator
N Queens problem
point to a rvalue
HeapDoubLinArr
PriorQ