marc
marc

Reputation: 2187

How can I test commands in Python? (Eclipse/PyDev)

I just setup PyDev with Eclipse, but I'm a little confused. I thought that in the console I would be able to type certain commands such as print("Hello World") and directly observe the result without having to incorporate that in any sort of file.

The reason I would like this is because it would allow me to test functions real quick before using them in scripts, and I'm also following a tutorial which tells me to check if NumPy is installed by typing import NumPy in the command line.

Thanks!

Upvotes: 0

Views: 133

Answers (2)

ford prefect
ford prefect

Reputation: 7388

Open up terminal and type python then it should load python shell then type import numpy

I have used pydev and find its easier just to use terminal to run small commands

Upvotes: 0

Denis
Denis

Reputation: 5271

There should be an interactive console in PyDev.

Try Ctrl+Alt+Enter or Cmd+Alt+Enter.

Upvotes: 1

Related Questions