94 th

Top 10% star Programming IQ

Edwin Chow performed better than 94 percent of candidates in terms of accuracy, measured by points earned, and speed, measured by time needed to find accurate answers.

Our “Programming IQ” assessment is designed to assess for Programming IQ rather than experience. For this reason, candidates are allowed to take the assessment in any language they prefer. A candidate who scores exceptionally well thinks like an engineer and will be able to quickly learn and adapt in any environment. Conversely, a candidate who scores poorly on this assessment is likely going to struggle in any environment, regardless of their experience level.

Competencies Tested
check Understanding of how variables work
check Understanding of how loops work
check Understanding of how arrays work
check Understanding of how conditionals work
check Understanding of how to create basic/intermediate functions
Questions
Q1: Log variable subtraction

Predict the output of the following code:

Loading...
Loading Replay...
Q2: Loop array log i

Predict the output of the following code:

Loading...
Loading Replay...
Q3: Loop array change values

Predict the output of the following code:

Loading...
Loading Replay...
Q4: Addexclamation

Create a function that takes a string (word) and adds "!" to the end of the string (word) before returning it. Example: addExclamation("hey") should return "hey!". You can assume the given string (word) will contain at least one character.

Loading...
Loading Replay...
Q5: Conditionalmultiplication

Create a function that will return the product (multiplication) of a given number multiplied by 2 if the given number is even, or multiplied by 5 if the given number is odd. Then return the updated number. Example: conditionalMultiplication(4) should return 8 because 4 is an even number, therefore, it should be multiplied by 2. You can assume the number will not be 0.

Loading...
Loading Replay...
Q6: Repeatarray

Create a function that takes an array (arr) of integers and returns an array that contains the same integers, in the same order. However, each value will be repeated twice(one after the other). You can assume the array (arr) will have at least one value in it. Example: repeatArray([1, 3, 5]) should return [1, 1, 3, 3, 5, 5]

Loading...
Loading Replay...
Q7: Multiplemovements

Create a function that takes 5 integers that relate to two starting points (start1, start2), two movement speeds (move1, move2), and the number of movements (num). Determine if after the given number of movements (num), the two starting points will finish at the same number after increasing their number by their respective movement speeds. If the two starting points end at the same number, return "YES", otherwise return "NO". Example: multipleMovements(start1, move1, start2, move2, num). multipleMovements(2,4,6,3,5) should return "NO" because after 5 movements, (start1) ended at 22, and (start2) ended at 21.

Loading...
Loading Replay...
Q8: Value index []

Create a function that returns the index of a given value (value) in a given array (arr) of integers. If the value (value) is not present in the array (arr), return -1. Example: passing [1,2,3,4,5] and 4 should return 3 (the index of 4 in the given array). You can assume the array (arr) will contain at least one value.

Loading...
Loading Replay...
Q9: Decode ""

Create a function that takes a string (code), and returns a new string. The given string (code) will have multiple pairs of a letter followed by a number. The number represents how many times the paired letter should be added, in sequence, to the final string. Example: passing "a3b2c1d3" should return "aaabbcddd". You can assume the string will contain at least one letter/number pair, all integers will be 1 digit, and no letters/numbers will be present unless in a pair.

Loading...
Loading Replay...
Q10: Checknums

Create a function that takes 2 integers (num1) and (num2) and returns true if (num2) is greater than (num1), return false if (num2) is less than (num1), otherwise return the string "equal".

Loading...
Loading Replay...
Q11: Arithmetic

Create a function that takes two numbers, (num1) and (num2), and returns an array that will contain four values. First, divide the two numbers (num1)/(num2) to get the quotient. Split the resulting quotient into 2 integers and then get their product. Split the resulting product into individual integers and add them to get their sum. Split the resulting sum into 2 integers and get their difference (first number) - (second number). The array that will be returned will be in the following format: [quotient, product, sum, difference]. If any of the calculations result in only one digit, use 0 as the first digit. Ex. arithmetic(36, 3): 36/3 = 12; 1*2 = 2; 0+2 = 2; 0-2 = -2; Result would be [ 12, 2, 2, -2 ]. You can assume the first number (num1) will be greater than the second number (num2) and that both numbers will be greater than zero.

Loading...
Loading Replay...
Q12: Getx

Create a function where a given integer (x) and an array (arr) returns the number at index (x) if the array was sorted in ascending order. Ex: getX(2, [5,10,-3,7,9]) will return 5 because when sorted, 5 is the 2nd number from the array You can assume the given array (arr) will always contain enough values to return a value at the given index

Loading...
Loading Replay...
Q13: Bestvaluepair

Create a function that takes an array of integers (arr) and an integer (num) and returns the sum of two values (in the given array), that is the highest possible sum WITHOUT going OVER the given integer (num). Example: bestValuePair([2,4,0,9],7) should return 6 because 4 + 2 is the highest possible pair of values that is not greater than the given number of 7. You can assume there will not be any ties for best value pair and that the given array (arr) will always contain one valid pair.

Loading...
Loading Replay...
Q14: Oddevenfib

Create a function where you can check if the number in the given position (num) of the Fibonacci sequence is odd or even. Treat (num) as the position, NOT the index. Consider the Fibonacci sequence to be an array of integers, starting with [0, 1, 1, ....]. Ex. oddEvenFib(5) will return "odd" because the fifth number in fibonacci sequence is 3 [0, 1, 1, 2, 3....].

Loading...
Loading Replay...
Comp ID Name Date Shared Percentile Score
No results found.

Share Your Assessment Report

Copy the provided URL and attach it to your resume if you want hiring managers to see your assessment report.

Successfully Copied!