Problem I’m trying to create a function with has 5 input parameters and returns the average of the 3 biggest. […]
Tag: array
php most elegant function call returning array [closed]
Problem Closed. This question is off-topic. It is not currently accepting answers. Questions must involve real code that you own […]
Structuring a JSON array with objects
Problem I have a JSON array or literal (passes through JSON.parse). Requirement: an array of tasks which contains operations which […]
Array kept contiguous by swapping with the last element
Problem I made a class that encapsulates the common pattern of keeping an array contiguous when an element is removed […]
Finding a max element in an array in Java
Problem Created the following method: public static int max(int[] array) { int max = Integer.MIN_VALUE; for (int value : array) […]
Partial Sudoku Verifier
Problem To practice my JavaScript for future employment, I’ve decided to take up the challenge of writing a javascript sudoku […]
Looping through an Array of objects to find an ID in a sub array
Problem I have an Array of objects, each which contain their own sub Tags Array, and I need to loop […]
Each item of the array must loop and show message for some time (duration) and repeat msg each value of delay
Problem Is there a better way to loop item of an array using forEach and make repeat it using setTimout/Interval […]
Check if two date ranges overlap by X minutes
Problem I have a list of volunteer shifts. The shifts are time ranges- for example, 9AM-2PM and 12PM-5PM. I need […]
How to create an array with 10 elements based on a maximum value [closed]
Problem Closed. This question is off-topic. It is not currently accepting answers. Code not implemented or not working as intended: […]