Samsung

2 DSA problems asked in Samsung coding interviews

2 Easy
0 Medium
0 Hard
​

2 problems

Sorting
1
Maximum Product of Two Elements in an Array
Easy

Given the array of integers `nums`, choose two different indices `i` and `j` and return the maximum value of `(nums[i] - 1) * (nums[j] - 1)`.

Trees
1
Two Sum IV - Input is a BST
Easy

Given the root of a binary search tree and an integer k, return true if there are two different nodes in the tree whose values add up to k, and false otherwise.