Sam's Club Interview Questions

Sam's Club Interview Guides

Click or hover over a slice to explore questions for that topic.
Machine Learning
(39)
SQL
(32)
Data Structures & Algorithms
(21)
A/B Testing
(15)
Product Sense & Metrics
(15)

Sam's Club Interview Questions

Practice for the Sam's Club interview with these recently asked interview questions.

QuestionTopicDifficulty
Data Structures & Algorithms
Medium

You are asked to develop a simple tag counter that will look for the occurrence of certain words or phrases in a piece of text.

You are given a paragraph as a string and a list of tag groups as a list of lists of strings. Write a tag_counter function that returns a list of integers with the number of times each tag in the tag group was used in the text.

Note: Your function should be case-insensitive with regards to the tag groups.

Example:

Input:

tag_groups = [
    ['data scientist', 'data analyst'], 
    ['data engineer', 'data wrangler'], 
    ['machine learning engineer'], 
    ['data' , 'engineer']]
text = "Today, with the advent of data science, different roles have emerged in the industry. Job postings are abundant of many names such as data scientist, data engineer, data wrangler, deep learning specialist, and machine learning specialist to name a few."

Output:

def tag_counter(tag_groups,text) -> [1, 2, 0, 5]
Data Structures & Algorithms
Easy
Machine Learning
Easy
Loading pricing options

View all Sam'S Club questions

Challenge

Check your skills...
How prepared are you for working at Sam'S Club?

Discussion & Interview Experiences

?
There are no comments yet. Start the conversation by leaving a comment.