Given a non-empty array of integers nums, return the smallest value in the array.
Example 1: Input: nums = [3,1,4,1,5] Output: 1
Example 2: Input: nums = [-8,-2,-9] Output: -9
Constraints: 1 <= nums.length <= 100 -1000 <= nums[i] <= 1000
Given a non-empty array of integers nums, return the smallest value in the array.
Example 1: Input: nums = [3,1,4,1,5] Output: 1
Example 2: Input: nums = [-8,-2,-9] Output: -9
Constraints: 1 <= nums.length <= 100 -1000 <= nums[i] <= 1000
Copyright 2026 algowars. All rights reserved.
Input 1 (integer_array)
[-8,-2,-9]
Output 1 (integer)
-9