Professional Documents
Culture Documents
Junior Unity Programmer Knowledge Test
Junior Unity Programmer Knowledge Test
We'd love for you to join the team, but first, we must conduct a series of noninvasive tests to see
how and where you'd best fit in. Please complete and return this test within 72 hours of
receiving it.
MATH
Q: Explain what are some of the uses of the Dot Product in Video Games?
A: Applications include finding projection of a force onto a specified axis. Checking whether 2
vectors are perpendicular. Finding work done by a force. Multiplication of matrices in linear
algebra involve taking dot product of the row in left matrix with column in right matrix
Q: Please describe how to find out if two circles (center and radius) collide?
A: We focus on the center point of both circles given by (x1+x22,y1+y22). The distance
between the centers of the circles is given by R=√(x2−x1)2+(y2−y1)2.
LANGUAGE C#
Q: In C# What is Inheritance, Polymorphism, and Encapsulation?
A: Inheritance: Through this feature you can define classes from other, more general, and only
add the properties and methods of specialization.
Polymorphism: is the ability of objects to react differently to
The same messages. For example an object of type Door, like an object of type
Window, you can receive the message Open; however, each of them will react so
different.
Encapsulation: It is the process that consists in organizing the data and operations (methods) of
a class that specifies its structure and behavior in order to prevent access to data by any means
other than the one specified and therefore the encapsulation of secured data the integrity of the
data contained in the object.
PROGRAMMING KNOWLEDGE
Q: What is your favorite Design Pattern and why?
A: I don’t
Q: Given an array of numbers, return the number that appears the most times.
A: One possible way to do this is to work with the matrices, matrix A and matrix R (of result).
The matrix R is initialized with 10 positions (from 0 to 9), all of them with a value of 0.
Using the matrix A and for each element, write down its value and access the specific position
of R and add a value. E.g. if A [0] == 2 (as is the case) access R [2] and have one.
At the end of R you have the number of times each value of A has appeared. In R [0] you have
the number 0s of A, in R [1] the number of 1s ...
To print those that only repeat, use R and for each value> 0 print the index and the value ... eg
If at the end R [0] == 0, but do not print 0, if R [1] == 2, print that the number 1 appears 2 times,
and then it will reach R [9].
This algorithm works the same as the length (# elements) of A, provided that the values of A are
between 0 and 9.
Q: You have two identical iPhones and a 100-floor building. The phones will not take any
damage from falling unless it is a specific floor or higher, at which point the dropped phone will
break. Your task is to determine the lowest floor that the phone will break. You may break both
phones in the process. As efficiently as possible, what is the largest number of drops required to
determine the exact floor the phone will break at?
A:
CONCLUSION
When you've finished with all the parts of the test, zip everything back up (including this file) and
email it back to us.