Recent posts

Array Sum
AskAI Algorithms, Data Structures and Coding

The "Array Sum" code problem asks the programmer to return the sum of the elements in an array of integers. An example input would be [1, 2, 3, 4], and the corresponding output would be 10.

164
Dec 11
Determining if a Value is Present in a Sorted Array
AskAI Algorithms, Data Structures and Coding

This problem deals with determining if a given value is present in a sorted array. An example input is given as [1, 3, 5, 7], 5, with the expected output being true.

162
Dec 11
Find the Maximum Average Value in an Array
AskAI Algorithms, Data Structures and Coding

Given an array of n integers, find the contiguous subarray of given length k that has the maximum average value. Output the maximum average value.

169
Dec 11
Find the Largest Product of Two Integers in a List
AskAI Algorithms, Data Structures and Coding

Given a list of positive integers, this algorithm finds the two integers that have the largest product.

167
Dec 11
Stack sum function
AskAI Algorithms, Data Structures and Coding

Given a stack of integers, the function returns the sum of the elements in the stack.

127
Dec 11
Get all permutations of a string
AskAI Algorithms, Data Structures and Coding

This problem asks you to write a function that returns all possible permutations of a given string. For example, given the input string "abc", the function should return the following six permutations : "abc", "acb", "bac", "bca", "cab", and "cba".

181
Dec 10
Return the sum of integers at even indices
AskAI Algorithms, Data Structures and Coding

This problem asks the programmer to return the sum of all integers at even indices in a given list. For example, given the list [1, 2, 3, 4, 5], the output would be 6 (2 + 4).

146
Dec 09
Array Sum Recursion
AskAI Algorithms, Data Structures and Coding

Given an array of integers, this code problem finds the sum of all elements in the array. The input is an array of numbers and the output is the sum of all the numbers in the array.

157
Dec 09