np.arange in python

>>> np.arange(3)
array([0, 1, 2])
>>> np.arange(3.0)
array([ 0.,  1.,  2.])
>>> np.arange(3,7)
array([3, 4, 5, 6])
>>> np.arange(3,7,2)
array([3, 5])

Here is what the above code is Doing:
1. The first line is creating an array of integers from 0 to 2.
2. The second line is creating an array of floats from 0 to 2.
3. The third line is creating an array of integers from 3 to 6.
4. The fourth line is creating an array of integers from 3 to 6, in steps of 2.

Note that the arange function takes in 3 parameters: start, stop, and step.
The start parameter is the starting value of the array. The stop parameter is the ending value of the array. The step parameter is the space between each value in the array.

If you don’t specify a step parameter, the default value is 1.

You can also use negative values for the step parameter. This will cause the array to count down instead of up.

>>> np.arange(5,1,-1)
array([5, 4, 3, 2])