You are given an array of integers nums and an integer target.
Your task is to determine if target exists in the array nums.
You may assume that:
Return true if target is found in nums, otherwise return false.
nums = [1, 2, 3, 4, 5]
target = 3
True
The value 3 is present in the array at index 2.
nums = [10, 20, 30]
target = 15
False
The value 15 is not present in the array.
nums = []
target = 1
False
An empty array contains no values.
nums = [1, 2, 3, 4, 5]
target = 3
True