Epic Systems
Callaway Golf Interview Questions and Answers
Q1. Given two sequences of length N, how to find the max window of matching patterns. The patterns can be mutated
To find max window of matching patterns between two sequences of length N with mutated patterns.
Create a sliding window of size N and traverse both sequences simultaneously.
Check for matching patterns in the window and keep track of the maximum window with matching patterns.
Use a hash table to keep track of mutated patterns.
If a pattern is mutated, update the hash table and check if it matches with the other sequence.
Repeat until the end of both sequences is reached.
Return th...read more
Q2. Given and Array of A[1..n] bits, find the length of longest consecutive substring of 0 and 1 such that number of 0s and 1s are equal?
Find length of longest consecutive substring of 0 and 1 with equal count in given array of bits.
Create a prefix array to store the difference between count of 0s and 1s till each index.
Find the first and last occurrence of each unique value in prefix array.
Calculate the length of the subarray between first and last occurrence of each unique value.
Return the maximum length of subarray with equal count of 0s and 1s.
Q3. How do you rotate a string of length n word by word with constant extra space in linear time ?
Rotate a string of length n word by word with constant extra space in linear time.
Reverse the entire string
Reverse each word in the string
Handle the last word separately
Time complexity: O(n)
Space complexity: O(1)
Q4. For example, seq1 = “ABCDEFG”, seq2 = “DBCAPFG”, then the max window is 4. (ABCD from seq1 and DBCA from seq2)
Find the maximum window size of common substring in two given sequences.
Use dynamic programming to find the length of longest common substring.
Slide a window of that length over both sequences to find the common substring.
If no common substring is found, decrease the window size and repeat.
Q5. Letter Combination of Phone Numbers
Generate all possible letter combinations of a phone number
Create a mapping of digits to letters
Use backtracking to generate all combinations
Handle edge cases like empty input or invalid digits
Q6. 2> you have one singly linked list, and you have pointer to one node, delete that node in o(1) time
Interview Process at Callaway Golf
Top Interview Questions from Similar Companies
Reviews
Interviews
Salaries
Users/Month