Write a Program to Find Unique Binary String
# 884. Find Unique Binary String
Given an array of strings nums containing n unique binary strings each of length n, return a binary string of length n that does not appear in nums. If there are multiple answers, you may return any of them.
### Example 1: ``` Input: nums = ["01","10"] Output: "11" Explanation: "11" does not appear in nums. "00" would also be correct. ```
### Example 2: ``` Input: nums = ["00","01"] Output: "11" Explanation: "11" does not appear in nums. "10" would also be correct. ```
Constraints: ``` n == nums.length 1 <= n <= 16 nums[i].length == n nums[i] is either '0' or '1'. All the strings of nums are unique. ```
/** * @param {string[]} nums * @return {string} */ var findDifferentBinaryString = function(nums) { let out = ''; for (let i = 0; i < nums.length; i++) { const item = nums[i]; out += item[i] === '0' ? '1' : '0'; } return out; };