You are given the heads of two sorted linked lists list1
and list2
.
Merge the two lists in a one sorted list. The list should be made by splicing together the nodes of the first two lists.
Return the head of the merged linked list.
// This is what I have in my project for relativeDueDate string | |
struct TaskItem { | |
... | |
var relativeDueDate: String { | |
let formatter = RelativeDateTimeFormatter() | |
formatter.dateTimeStyle = .named | |
return formatter.localizedString(for: dueDate, relativeTo: .now).capitalizingFirstLetter() | |
} | |
} |
You are given the heads of two sorted linked lists list1
and list2
.
Merge the two lists in a one sorted list. The list should be made by splicing together the nodes of the first two lists.
Return the head of the merged linked list.
Given the head of a singly linked list, return true if it is a palindrome.
Input: head = [1,2,2,1]
Output: true
You are given an array prices
where prices[i]
is the price of a given stock on the ith
day.
You want to maximize your profit by choosing a single day to buy one stock and choosing a different day in the future to sell that stock.
Return the maximum profit you can achieve from this transaction. If you cannot achieve any profit, return 0
.
Input: prices = [7,1,5,3,6,4]
Given a binary tree, determine if it is height-balanced.
For this problem, a height-balanced binary tree is defined as:
a binary tree in which the left and right subtrees of every node differ in height by no more than 1.
Input: root = [3,9,20,null,null,15,7]
Output: true
Given two integer arrays preorder
and inorder
where preorder
is the preorder traversal of a binary tree and inorder
is the inorder traversal of the same tree, construct and return the binary tree.
Input: preorder = [3,9,20,15,7], inorder = [9,3,15,20,7]
Output: [3,9,20,null,null,15,7]
A phrase is a palindrome if, after converting all uppercase letters into lowercase letters and removing all non-alphanumeric characters, it reads the same forward and backward. Alphanumeric characters include letters and numbers.
Given a string s
, return true
if it is a palindrome, or false
otherwise.
Input: s = "A man, a plan, a canal: Panama"
SQL Server + Jetbrains Rider for Mac (M1/Intel) - Updated for 2022 - Detailed Demo
SQL Server + Visual Studio for Mac (M1/Intel) - Updated for 2022 - Detailed Demo
This is only for sharing purpose. If you encounter any issues, please kindly do your due diligence Googling them first. I'm new to this and still learning too.