Data Scientist Interview Questions

Review this list of 125 data scientist interview questions and answers verified by hiring managers and candidates.
  • Adobe logoAsked at Adobe 

    "static boolean sudokuSolve(char board) { return sudokuSolve(board, 0, 0); } static boolean sudokuSolve(char board, int r, int c) { if(c>=board[0].length) { r=r+1; c=0; } if(r>=board.length) return true; if(boardr=='.') { for(int num=1; num<=9; num++) { boardr=(char)('0' + num); if(isValidPosition(board, r, c)) { if(sudokuSolve(board, r, c+1)) return true; } boardr='.'; } } else { return sudokuSolve(board, r, c+1); } return false; } static boolean isValidPosition(char b"

    Divya R. - "static boolean sudokuSolve(char board) { return sudokuSolve(board, 0, 0); } static boolean sudokuSolve(char board, int r, int c) { if(c>=board[0].length) { r=r+1; c=0; } if(r>=board.length) return true; if(boardr=='.') { for(int num=1; num<=9; num++) { boardr=(char)('0' + num); if(isValidPosition(board, r, c)) { if(sudokuSolve(board, r, c+1)) return true; } boardr='.'; } } else { return sudokuSolve(board, r, c+1); } return false; } static boolean isValidPosition(char b"See full answer

    Data Scientist
    Data Structures & Algorithms
    +4 more
  • TikTok logoAsked at TikTok 

    "I generate insights through stakeholder requirements and the data I have in hand"

    Anonymous Eagle - "I generate insights through stakeholder requirements and the data I have in hand"See full answer

    Data Scientist
    Analytical
  • McKinsey logoAsked at McKinsey 
    Data Scientist
    Analytical
    +1 more
  • Adobe logoAsked at Adobe 
    +7

    "from typing import List def traprainwater(height: List[int]) -> int: if not height: return 0 l, r = 0, len(height) - 1 leftMax, rightMax = height[l], height[r] res = 0 while l < r: if leftMax < rightMax: l += 1 leftMax = max(leftMax, height[l]) res += leftMax - height[l] else: r -= 1 rightMax = max(rightMax, height[r]) "

    Anonymous Roadrunner - "from typing import List def traprainwater(height: List[int]) -> int: if not height: return 0 l, r = 0, len(height) - 1 leftMax, rightMax = height[l], height[r] res = 0 while l < r: if leftMax < rightMax: l += 1 leftMax = max(leftMax, height[l]) res += leftMax - height[l] else: r -= 1 rightMax = max(rightMax, height[r]) "See full answer

    Data Scientist
    Data Structures & Algorithms
    +4 more
  • Slack logoAsked at Slack 

    "The only time I felt unhappy at work was when I didn’t get to pick the job I want to do at the jobsite."

    Amparo L. - "The only time I felt unhappy at work was when I didn’t get to pick the job I want to do at the jobsite."See full answer

    Data Scientist
    Behavioral
  • 🧠 Want an expert answer to a question? Saving questions lets us know what content to make next.

  • Discord logoAsked at Discord 
    Data Scientist
    Behavioral
    +2 more
  • Tinder logoAsked at Tinder 
    Data Scientist
    Behavioral
  • Salesforce logoAsked at Salesforce 
    Data Scientist
    Behavioral
    +4 more
  • Data Scientist
    Concept
    +1 more
  • Apple logoAsked at Apple 

    Coin Change

    IDE
    Medium
    +6

    "The example given is wrong. The 2nd test case should have answer 3, as we can get to 6 by using 3 coins of denomination 2."

    Anmol R. - "The example given is wrong. The 2nd test case should have answer 3, as we can get to 6 by using 3 coins of denomination 2."See full answer

    Data Scientist
    Coding
    +3 more
  • Tinder logoAsked at Tinder 

    "I would recognize the factors that are causing the interference. Then i will use tools like smoothing techniques or algorithms (e.g Kalman filters for time series) which can help isolate genuine trends from noise. In testing i would employ techniqu es like A/B testing to measure interference from unrelated factors and use techniques like regression analysis to seperate the relevant factors from noise."

    Trusha M. - "I would recognize the factors that are causing the interference. Then i will use tools like smoothing techniques or algorithms (e.g Kalman filters for time series) which can help isolate genuine trends from noise. In testing i would employ techniqu es like A/B testing to measure interference from unrelated factors and use techniques like regression analysis to seperate the relevant factors from noise."See full answer

    Data Scientist
    Technical
  • Apple logoAsked at Apple 
    +2

    "Make current as root. 2 while current is not null, if p and q are less than current, go left. If p and q are greater than current, go right. else return current. return null"

    Vaibhav D. - "Make current as root. 2 while current is not null, if p and q are less than current, go left. If p and q are greater than current, go right. else return current. return null"See full answer

    Data Scientist
    Data Structures & Algorithms
    +4 more
  • Infosys logoAsked at Infosys 

    "In Python, an "oops" (Object-Oriented Programming) concept refers to a programming paradigm that is based on the idea of objects and classes. OOP allows developers to model real-world concepts and create reusable code blocks through the use of inheritance, polymorphism, and encapsulation. Here are some common OOP concepts in Python: Class: A class is a blueprint for creating objects. It defines the attributes and behaviors that objects of that class will have. Object: An object is an insta"

    Anonymous Flamingo - "In Python, an "oops" (Object-Oriented Programming) concept refers to a programming paradigm that is based on the idea of objects and classes. OOP allows developers to model real-world concepts and create reusable code blocks through the use of inheritance, polymorphism, and encapsulation. Here are some common OOP concepts in Python: Class: A class is a blueprint for creating objects. It defines the attributes and behaviors that objects of that class will have. Object: An object is an insta"See full answer

    Data Scientist
    Technical
  • "Number of employees after the first year = n*(1+r) = n1 Number of employees after the second year = n1(1+r) = n(1+r)**2 Hence, the number of employees after 't' years = n(1+r)*t"

    Asish B. - "Number of employees after the first year = n*(1+r) = n1 Number of employees after the second year = n1(1+r) = n(1+r)**2 Hence, the number of employees after 't' years = n(1+r)*t"See full answer

    Data Scientist
    Concept
  • Figma logoAsked at Figma 
    Data Scientist
    Behavioral
  • Adobe logoAsked at Adobe 

    "Leetcode 347: Heap + Hashtable Follow up question: create heap with the length of K instead of N (more time complexity but less space )"

    Chen J. - "Leetcode 347: Heap + Hashtable Follow up question: create heap with the length of K instead of N (more time complexity but less space )"See full answer

    Data Scientist
    Coding
    +3 more
  • Oracle logoAsked at Oracle 

    "def countuniqueoutfits(totalpants: int, uniquepants: int, totalshirts: int, uniqueshirts: int, totalhats: int, uniquehats: int) -> int: """ Number of unique outfits can simply be defined by (uniquepantschoose1uniqueshirtschoose1uniquehatschoose_1) (uniquepantschoose1*uniqueshirtschoose1) # Not wearing a hat nchoosek is n """ res = (uniquepants*uniqueshirtsuniquehats) + (uniquepantsunique_shirts) return res print(countuniqueoutfits(2, 1, 1, 1, 3, 2))"

    Sai R. - "def countuniqueoutfits(totalpants: int, uniquepants: int, totalshirts: int, uniqueshirts: int, totalhats: int, uniquehats: int) -> int: """ Number of unique outfits can simply be defined by (uniquepantschoose1uniqueshirtschoose1uniquehatschoose_1) (uniquepantschoose1*uniqueshirtschoose1) # Not wearing a hat nchoosek is n """ res = (uniquepants*uniqueshirtsuniquehats) + (uniquepantsunique_shirts) return res print(countuniqueoutfits(2, 1, 1, 1, 3, 2))"See full answer

    Data Scientist
    Coding
  • Tinder logoAsked at Tinder 
    Data Scientist
    Behavioral
  • Adobe logoAsked at Adobe 

    "#include #include #include using namespace std; void printComs(int prev, int start, int end, int target) { if (start >= end) return; while (start target) { end--; } else { st"

    Iris F. - "#include #include #include using namespace std; void printComs(int prev, int start, int end, int target) { if (start >= end) return; while (start target) { end--; } else { st"See full answer

    Data Scientist
    Data Structures & Algorithms
    +4 more
  • "label #shape = [batchsize, posids] X #shape = [batch_size, ch] hidden = nn.Linear(batchsize, ch) #shape = [batchsize, ch] logits = nn.Linear(ch, C) #shape = [ch, C] #modifications start here neg_ids = torch.randint(0, C, 0.1 * C) #e.g. if we want to randomly sample only 10% of C outputneg = np.dot(logits[:, negids], hidden(X)) #shape [batch_size, C1] outputpos = np.dot(logits[:, posids], hidden(X)) #shape [batch_size, C2] output = torch.concat(outputpos, outputneg) #concatenate out"

    Anonymous Hornet - "label #shape = [batchsize, posids] X #shape = [batch_size, ch] hidden = nn.Linear(batchsize, ch) #shape = [batchsize, ch] logits = nn.Linear(ch, C) #shape = [ch, C] #modifications start here neg_ids = torch.randint(0, C, 0.1 * C) #e.g. if we want to randomly sample only 10% of C outputneg = np.dot(logits[:, negids], hidden(X)) #shape [batch_size, C1] outputpos = np.dot(logits[:, posids], hidden(X)) #shape [batch_size, C2] output = torch.concat(outputpos, outputneg) #concatenate out"See full answer

    Data Scientist
    Program Sense
Showing 101-120 of 125