Terms Of AP Ayush is given a number ‘X’. He has been told that he has to find the first ‘X’ terms of the series 3 * ‘N’ + 2, which are not multiples of 4. Help Ayush to find it as he has not been able to answer. Example: Given an ‘X’ = 4. The output array/list which must be passed to Ayush will be [ 5, 11, 14, 17 ]. In...
read more
CodingNinjas
author
2y
Approach :1) Declare a temporary array/list variable ‘ANS’ in which we store our answer.2) Declare a temporary variable ‘GOT’ that will store the total number of elements we obtained until now, which ...
see more
CodingNinjas
author
2y
Brute ForceThe basic idea of this approach is to iterate through all the elements obtained in series 3 * ‘N’ + 2. We will see if the number is divisible by 4 or not. If it is acceptable, then we will ...
see more
Help your peers!
Add answer anonymously...
Top GlobalLogic Software Developer interview questions & answers
Popular interview questions of Software Developer
Top HR questions asked in GlobalLogic Software Developer
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