Ordered Squares of a Sorted List

Asked at Uber · Coding Questions · Difficulty: Easy · Last asked Mar 21, 2026

A list of integers is sorted in non-decreasing order and may contain negative numbers. Return a new list with the square of every entry, also in non-decreasing order.

Loading the problem…