Creating NumPy Arrays

  1. np.zeros(): It is used to create an array of 0s.
  2. np.random.randint(): It is used to create a random array of integers within a particular range.
  3. np.random.random(): It is used to create an array of random numbers.
  4. np.arange(): It is used to create an array with increments of fixed step size.
  5. np.linspace(): It is used to create an array of fixed length.

--

--

--

Tech enthusiastic, life explorer, single, motivator, blogger, writer, software engineer

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

JavaScript

Some code snips

How to create a slider with React Hooks and TypeScript

Vim search replace all files in current (project) folder

🤖 Automate and streamline your workflow {web developer}

Understanding ES6 Javascript Better

Create CLI application in NodeJS

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
TechGuy

TechGuy

Tech enthusiastic, life explorer, single, motivator, blogger, writer, software engineer

More from Medium

How to use IFERROR function in Excel?

Let’s learn about RDD…

Data Types in JVM

Data Types in JVM

#100DaysofCode — Day[4] (5)