iOS Developer Interview Questions
- 0of 0 votes
AnswerAre there progressing costs once my application is discharged?
- markstarc14 March 28, 2019 in United States| Report Duplicate | Flag | PURGE
AppPerfect iOS Developer - 0of 0 votes
AnswerRegardless of whether you need an iOS or an Android App?
- markstarc14 March 28, 2019 in United States| Report Duplicate | Flag | PURGE
AppPerfect iOS Developer - 0of 0 votes
AnswerFor what reason would You Like to Develop an App?
- markstarc14 March 28, 2019 in United States| Report Duplicate | Flag | PURGE
AppPerfect iOS Developer - 0of 0 votes
AnswerHow Do I Manage Different Display Resolutions?
- markstarc14 March 28, 2019 in United States| Report Duplicate | Flag | PURGE
AppPerfect iOS Developer - 0of 0 votes
AnswerWhat is the most ideal approach to get my application found?
- markstarc14 March 28, 2019 in United States| Report Duplicate | Flag | PURGE
AppPerfect iOS Developer - 3of 3 votes
AnswerHow would you work with a backend engineer to design a news feed on mobile. Imagine that we only care about showing the user feed and posting a picture.
- tbag February 15, 2018 in United States
Follow-ups
1. what kind of apis would you want him to expose and what would they look like
2. How would you refresh the news feed on the iOS app and how often?
3. How would you cache the data/images. What size cache would you have?| Report Duplicate | Flag | PURGE
Facebook iOS Developer System Design - -1of 1 vote
Answershttps://gist.github.com/acegreen/e16a2259a93dab880a7f
- aelalfy1989 March 09, 2016 in United States| Report Duplicate | Flag | PURGE
Groupon iOS Developer Algorithm - 0of 0 votes
Answershttps://gist.github.com/acegreen/1a9a63f27729278b0fa5
- aelalfy1989 March 09, 2016 in United States| Report Duplicate | Flag | PURGE
Groupon iOS Developer Algorithm - 1of 1 vote
AnswersCounting the islands.
- byPaco September 15, 2015 in United States
Given a map N x N, 2-D array
0 - sea
X - land
Land is connected by 4-Neighbor connections, i.e.: above, down, left and right.
00000000000000000000000000000000000
00000000000000000000000000000000000
00000000000000000000000000000000000
0000000000000000000X000000000000000
000000000000000000XXX00000000000000
000XX000000000000000000000000000000
000XXXX0000000000000000000000000000
0000000X000000000000000000000000000
00000000000000000000000000000000000
000000000000000000000X0000000000000
00000000000000000000000000000000000
00000000000000000000000000000000000
00000000000000000000000000000000000
00000000000000000000000000000000000
00000000000000000000000000000000000
00000000000000000000000000000000000
00000000000000000000000000000000000
00000000000000000000000000000000000
Output of this map: 4 (totally 4 islands on the map)| Report Duplicate | Flag | PURGE
Google iOS Developer - 2of 2 votes
AnswersNumber list compressing.
- byPaco September 15, 2015 in United States
Given an sorted array. Input: sorted number list
1, 2, 3,10, 25, 26, 30, 31, 32, 33
Output: find consecutive segments
print: 1-3, 10, 25-26, 30-33| Report Duplicate | Flag | PURGE
Google iOS Developer - 2of 2 votes
Answers(To write in Objective-C; I will write the EXACT question)
- matteogobbi.jobs August 26, 2014 in United States
Given a dictionary of words, return an array of the words whose match. (i.e. pattern "c.t" match with "cat", "cut", etc. because the dot notation stand for ANY character).
SUGGEST: use suffix tree, for(for()) is not a good solution.| Report Duplicate | Flag | PURGE
Facebook iOS Developer Algorithm - 5of 5 votes
AnswersGiven a self-balancing tree (AVL), code a method that returns the median.
- Diego May 16, 2014 in United States
(Median: the numerical value separating the higher half of a data sample from the lower half. Example: if the series is
2, 7, 4, 9, 1, 5, 8, 3, 6
then the median is 5.)| Report Duplicate | Flag | PURGE
Facebook iOS Developer Trees and Graphs - 3of 3 votes
AnswersCreate the data structure for a component that will receive a series of numbers over the time and, when asked, returns the median of all received elements.
(Median: the numerical value separating the higher half of a data sample from the lower half. Example: if the series is
2, 7, 4, 9, 1, 5, 8, 3, 6
then the median is 5.)
Model the data structure for a component that would have these two methods:@interface SampleHandler { - (void)addNumber:(NSNumber*)number; - (NSNumber*)median; }
Justify your decisions. Calculate the complexity of each method.
- Diego May 16, 2014 in United States| Report Duplicate | Flag | PURGE
Facebook iOS Developer Data Structures - 0of 0 votes
AnswersGiven the following filename/rules:
- valheru April 23, 2014 in United States
johndoe_sdfjkldfj_ldfjlkfdsjfds_dfdjklfdsjs.txt
Rules:
johndoe is a distinct identifier (not a constant)
any following items are tacked on with underscores separating them and each token contains a key value pair. The key is the first character and the value is the remaining characters.
Parse this filename and return a dictionary/hashtable of values, removing any file extensions but also keeping in mind that this filename could end up with incorrect characters or incorrect amounts of characters.
Example input:
johndoe_sdfjkldfj_ldfjlkfdsjfds_dfdjklfdsjs.txt
Example output:
@{ @"NAME" : @"johndoe",
@"s" : @"dfjkldfj",
@"l" : @"dfjlkfdsjfds",
@"d": @"fdjklfdsjs"
};
Followup: How would you handle it if you found multiple tokens with the same key?| Report Duplicate | Flag | PURGE
Big Fish iOS Developer Algorithm - 0of 0 votes
AnswersDesign and code the logic software for an elevator, pretending like the hardware is already there for you with the following APIs:
- valheru April 23, 2014 in United States
- OpenDoor()
- GotoFloor()| Report Duplicate | Flag | PURGE
Big Fish iOS Developer System Design - 0of 0 votes
AnswersGiven 2 sorted lists that are of even and equal size, output the median. If there is no middle number, return the average of the 2 middle numbers
- valheru April 23, 2014 in United States| Report Duplicate | Flag | PURGE
Big Fish iOS Developer Sorting Amazon SDE-2 Algorithm - 2of 2 votes
AnswersGiven an array of words, write a method that determines whether there are any words in this array that are anagrams of each other.
- valheru April 23, 2014 in United States
Sample #1: @[@"bag", @"bat", @"tab"]; // output TRUE
Sample #2: @[@"gab", @"bat", @"laf"]; // output FALSE| Report Duplicate | Flag | PURGE
Facebook iOS Developer Algorithm - 0of 0 votes
AnswersAn UIView A2 is subclassed from the same parent as an UIView A1.
- valheru April 23, 2014 in United States
Given inputs of A1, A2, and an UIView that is in the tree of UIViews of A1 somewhere, return the exact UIView that mirrors this in A2.
Example setup:
A1------------
| |
UIView UIView
|
UIView <-- Given this
A2------------
| |
UIView UIView
|
UIView <-- Find/return this| Report Duplicate | Flag | PURGE
Facebook iOS Developer Trees and Graphs - 1of 1 vote
AnswersGiven a list of n sorted lists of numbers, write a method that returns one giant list of all the numbers in order.
- valheru April 23, 2014 in United States
Example input:
NSArray* input = @[
@[@2, @5, @10],
@[@25, @100, @105],
@[@7, @56, @42],
.......
];| Report Duplicate | Flag | PURGE
Facebook iOS Developer Sorting - 4of 4 votes
AnswersGiven the following hashmap for numeric to alpha translation of a telephone keypad:
- valheru April 23, 2014 in United States
NSDictionary* dict = @{@2: @[@"A", @"B", @"C"],
@3: @[@"D", @"E", @"F"],
@4: @[@"G", @"H", @"I"],
@5: @[@"J", @"K", @"L"],
@6: @[@"M", @"N", @"O"],
@7: @[@"P", @"Q", @"R", @"S"],
@8: @[@"T", @"U", @"V"],
@9: @[@"W", @"X", @"Y", @"Z"]};
Write a method that takes a phone number as input and returns all possible letter combinations for that phone number.| Report Duplicate | Flag | PURGE
Facebook iOS Developer Algorithm - -9of 11 votes
AnswersWhat are the screen dimensions of various iPhone models?
- thinkrightthru February 20, 2014 in India| Report Duplicate | Flag | PURGE
Facebook iOS Developer Graphics - -8of 8 votes
AnswersWhat is the screen dimensions of various iPhone models?
- thinkrightthru February 20, 2014 in India| Report Duplicate | Flag | PURGE
Facebook iOS Developer Graphics - 1of 1 vote
AnswersStakeout
- mike@unitedrmr.com January 12, 2014 in United States
Congratulations! You are the new elite hacker in a group of villainous ne'er-do-wells.
Luckily this group is more saavy than your last band of ruffians, and they are looking to software (and you) to improve their take. The con man for the team, has gone door-to-door down each street posing as a termite inspector so he could covertly total the valuable goods in each house. Normally the gang would just rob all the valuable homes, but there's a catch! Whenever a house is robbed in this wealthy neighborhood, the police watch it and the neighboring houses for months.
So the gang can't simply rob all the homes, and if they choose to rob one, they can no longer rob the house on either side of it.
The ringleader wants to know what houses he should rob to maximize the team's profit, and he wants to know now. Write a function that takes in an array of positive integers (home values) and returns the maximum expected value of robbing that street.
For example:
[ 20, 10, 50, 5, 1 ] should return $71, as robbing the first, third, and fifth houses is optimal [ 20, x, 50, x, 1 ]
[ 20, 50, 10, 1, 5 ] should return $55, as robbing the second and fifth houses is optimal [ x, 50, x, x, 5 ]| Report Duplicate | Flag | PURGE
iOS Developer - -2of 4 votes
AnswersLook at the following pseudo-code, which computes the n-th Fibonacci number:
- Eliana December 24, 2013 in United States for interviews
int fibonacci(int n)
{
if (n == 0)
{
print(0)
return 0
}
if (n == 1)
{
print(1)
return 1
}
return fibonacci(n - 1) + fibonacci(n - 2)
}
If one calls fibonacci(3), then the following will happen:
* fibonacci(3) calls fibonacci(2) and fibonacci(1) (the first call).
* fibonacci(2) calls fibonacci(1) (the second call) and fibonacci(0).
* The second call of fibonacci(1) prints 1 and returns 1.
* fibonacci(0) prints 0 and returns 0.
* fibonacci(2) gets the results of fibonacci(1) and fibonacci(0) and returns 1.
* The first call of fibonacci(1) prints 1 and returns 1.
* fibonacci(3) gets the results of fibonacci(2) and fibonacci(1) and returns 2.
In total, 1 will be printed twice and 0 will be printed once.
We want to know how many times 0 and 1 will be printed for a given integer N.
INPUT
The first line contains an integer T, denoting the number of test cases.
The next T lines contain an integer N.
OUTPUT
For each test case, print one line of output which contains 2 integers separated by a space. The first integer is the number of times 0 is printed. The second integer is the number of times 1 is printed.
CONSTRAINTS
1 <= T <= 50
0 <= N <= 40
SAMPLE INPUT
2
0
3
SMAPLEOUTPUT
1 0
1 2| Report Duplicate | Flag | PURGE
Informatica iOS Developer C++ - -2of 2 votes
AnswersThe way a Knight Given a chessboard, consisting of n×n cells, several of them are cut. Find the path of minimum length for a Knight from one cell to another. The Knight can’t go through cut cells.
- Eliana December 24, 2013 in United States for interviews
Specifications
Input
The first row is set to the number n (2 ≤ n ≤ 50). Each of the next n lines contains n symbols. The symbol # denotes the cut cell, the point - not cut cell, the symbol @ denotes the initial and final cell of the Knight's path (the chessboard contains two such characters).
Output If the path can not be constructed, print "Impossible". Otherwise display the same map as the input, but check all Knight intermediate positions with symbol @. Example
Example input
5
.....
.@@..
.....
.....
.....
5
@..@.
..##.
.....
.....
.....
5
@....
..#..
.#...
.....
....@
Example output
Sample 1
...@.
.@@..
....@
.....
.....
Sample 2
@..@.
..##.
.@..@
..@..
@....
Sample 3
Impossible| Report Duplicate | Flag | PURGE
Informatica iOS Developer C - 1of 3 votes
AnswersC={1,2,2,3,4,5}
- fgfsdgs November 09, 2013 in United States
Sum=5
subset;
{1,2,2}
{1,4}
{2,3}
using exhaustive force in java
ideas| Report Duplicate | Flag | PURGE
Palantir Technology iOS Developer Java - 1of 1 vote
AnswersGiven an array, remove the duplicates and return a unique array keeping the first occurrence of the duplicates and the order.
- kchronis October 29, 2013 in United States for iOS
[@2, @1, @3, @1, @2] --> [@2, @1, @3]| Report Duplicate | Flag | PURGE
Facebook iOS Developer Arrays - 15of 15 votes
AnswersGiven a set of 2D points, some integer k, find the k points closest to the origin, (0,0).
- peetonn March 09, 2013 in United States| Report Duplicate | Flag | PURGE
Facebook iOS Developer Algorithm - 1of 1 vote
AnswerHow will you describe iOS manual memory management for a new developer in few words?
- peetonn March 09, 2013 in United States| Report Duplicate | Flag | PURGE
Facebook iOS Developer System Design - 0of 2 votes
AnswersHow would you implement call for canceling queued blocks with dispatch_after?
- peetonn March 09, 2013 in United States| Report Duplicate | Flag | PURGE
Facebook iOS Developer Threads