Given an integer array nums, print all of its elements in order, separated by spaces.
Write a function that takes the array and prints its elements (it does not need to return anything). This is a warm-up to get comfortable reading an array and printing output.
Input: An array of integers nums.
Output: The elements printed in order (a single space between them; nothing for an empty array).
Input: nums = [1, 2, 3, 4, 5]
Output: 1 2 3 4 5
Explanation: Print each element in order.Input: nums = [10]
Output: 10
Explanation: A single element.Input: nums = [-1, 0, 5]
Output: -1 0 5
Explanation: Negatives are printed as-is.0 <= nums.length <= 1000-1000 <= nums[i] <= 1000