Skip to content

Latest commit

 

History

History
21 lines (17 loc) · 914 Bytes

README.md

File metadata and controls

21 lines (17 loc) · 914 Bytes

Welcome

A simple 3 problem test, for your consideration. Please fork the project and submit your solutions in a pull request.

Simple Problem1

Given an integer array of size N, compute the sum of all even numbers in this array
[1 point]

Simple Problem2

Given an integer array of size N, identify the largest 2 numbers in this array. Do not sort the array.
[2 points]

Simple Problem3

Given an array of numbers having size N in which every number is between 1 and N, determine if there are any duplicates in it. You are allowed to destroy the array if you like. Do not sort the array or use bit vectors. Try to work within the array without using any other temporary data structures. Do not use 2 nesting for loops since the time complexity would be high. Try to find a solution by executing just one loop.
Hint: manipulate the elements of the same array as you loop through.
[7 points]