Write a program to find the greatest from the list of elements within a window range, where window size is 3.
AnswerBot
1mo
Program to find greatest element in a window of size 3
Iterate through the list and maintain a window of size 3
Find the maximum element in each window and store it in a separate list
Return the list of ...read more
Help your peers!
Add answer anonymously...
Popular interview questions of AWS Data Engineer
Stay ahead in your career. Get AmbitionBox app
Helping over 1 Crore job seekers every month in choosing their right fit company
65 L+
Reviews
4 L+
Interviews
4 Cr+
Salaries
1 Cr+
Users/Month
Contribute to help millions
Get AmbitionBox app