you were given two lists check the divisibility of elements in list 1 with list two and print out the elements which are divisible.
AnswerBot
8mo
Check divisibility of elements in two lists and print divisible elements.
Iterate through elements in list 1 and list 2
Check if element in list 1 is divisible by element in list 2
Print out the elements...read more
Smit Trivedi
8mo
const list1 = [10, 15, 20, 25, 30]; const list2 = [2, 5]; // Function to check divisibility and print elements function checkDivisibility(list1, list2) { const divisibleElements = []; // Iterate throu...read more
Help your peers!
Add answer anonymously...
Popular interview questions of Software Developer
>
Ingersoll Rand Software Developer Interview Questions
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