Problem: Given an array of integers, find the subarray with the maximal/minimal sum. Continue reading

# Category Archives: programming problems

# Factor N given e and d

Problem: Given a pair of public and private RSA keys, factor N into p and q. Continue reading

# square and multiply

Problem: Modular exponentiation. Continue reading

# Popcount

Problem: Given a 32-bit integer, return the number of set bits in its binary representation. Continue reading

# Sliding window min/max

Problem: Given an array of numbers, find the min/max of a fixed-size sliding window over each index in the array Continue reading

# Next greater element

Problem: Given an array of numbers, for each element find its next greater element. Continue reading