Dataford
Interview QuestionsInterview GuidesExperiencesMock InterviewsPricing
Get started

Find Transaction IDs Not in Second List

EasyPython00:00
Practice interviewer
In session
5 left
00:00

Your question is Find Transaction IDs Not in Second List. Start with the requirements on the right.

Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.

You need to log in / sign up to run or submit.

Problem

Given two lists of transaction IDs, list1 and list2, return a list of transaction IDs that exist in list1 but not in list2.

Constraints

  • 1 <= list1.length, list2.length <= 10^5
  • Transaction IDs are strings with a maximum length of 100 characters

Function Signature

def find_missing_transactions(list1, list2):
Your solutionPython 3
You need to log in / sign up to run or submit.
Run your code to see test output