Меню Рубрики

Установка idle python ubuntu

How to Install IDLE Python IDE on your Ubuntu

What is IDLE?

IDLE stands for Integrated DeveLopment Environment. It is an IDE for Python, written in Python language itself and based on Tkinter with bindings to the Tk widget set. IDLE is most suitable for beginners as it has a simple IDE feature list. Hence, it is very popular in educational environments.

  • Multi-window text editor with syntax highlighting, auto-completion, smart indent and other.
  • Python shell with syntax highlighting.
  • Integrated debugger with stepping, persistent breakpoints, and call stack visibility.

For more information on IDLE, visit the following official documentation:

In this article, we will be installing IDLE through the Ubuntu command line. The article also explains how to launch IDLE and use it to write and run a simple Python script.

We have run the commands and procedures mentioned in this article on a Ubuntu 18.04 LTS system.

How to Install IDLE?

Python is installed by default on all the latest Ubuntu releases and it also usually comes with the IDLE application. However, if you have a minimal installation of Ubuntu that lacks any IDLE UI application, you can install it by following this method:

Open the Ubuntu command line, The Terminal, either through the system Dash or the Ctrl+Alt+T shortcut.

Then, you need to update your system’s repository index through the following command as sudo:

This way your system’s repository gets in-line with the Internet repositories and that helps you in installing the latest version of any available software.

You need to run this command as sudo because only an authorized user can add/remove, update, and configure software on Ubuntu. The system will ask you the password for sudo and then execute the rest of the command when you have provided a correct password.

The next step is to run the following command in order to install > Advertisements

The system might ask you for a Y/n input in order to make sure that you indeed want to install the software. Please enter Y and then hit Enter, after which IDLE3 will be installed on your system.

Launch IDLE

Run the following command in the Terminal in order to launch IDLE.

Or else, enter keywords relevant to IDLE in your Ubuntu Dash search as follows:

This will list all the IDLE applications installed on your system. Click on any one of them to Launch the Python integrated development environment.

Your first Python program in IDLE

Your first line of code starts from where you see the three “greater than” or “>” symbols.

Place the cursor at this point and write or copy & paste the following line of code:

This is a simple print statement that can be used to print anything inside the parentheses “( )”, on the screen.

When you hit Enter, the output is displayed as follows:

You can even choose to save the program (through the Save/Save As option from the File menu) and access it later (through the Open option from the File menu or directly by clicking it from where you have saved it).

Читайте также:  Установка защитных уголков на гкл

After reading this article, you can integrate this Python development environment into your Ubuntu system and make the best use of its UI-based simple and easy to use feature set.

источник

nix Craft

Linux and Unix tutorials for new and seasoned sysadmin

nix Craft

Linux and Unix tutorials for new and seasoned sysadmin

HowTo: Install Python >last updated May 25, 2013 in Categories Python

P ython is preinstalled on my Ubuntu / Debian Linux desktop. I’m unable to find IDLE integrated development environment for Python. How do I install IDLE IDE?

IDLE is an integrated development environment for Python. You need to install the following package:

Adblock detected 😱
  1. python-tools : This RHEL / CentOS / Fedora Linux package for IDLE includes several tools to help with the development of Python programs, including IDLE (an IDE with editing and debugging facilities), a color editor (pynche), and a python gettext program (pygettext.py).
  2. idle – This Debian or Ubuntu Linux meta package for IDLE. You may need to install idle-python2.5 package for Python v2.5, idle-python2.6 package for Python v2.6, idle-python3.1 package for Python v3.1.

IDLE Linux Installation

If you are using Debian / Ubuntu Linxu, type the following apt-get command to install idle IDE:
$ sudo apt-get install idle

If you are using RHEL / CentOS / Scientifc / Fedora Linxu, type the following yum command to install idle IDE:
# yum install python-tools

How do I start IDLE under Linux?

Type the following command:
$ idle
OR Visit menu option

See also

Posted by: Vivek Gite

The author is the creator of nixCraft and a seasoned sysadmin, DevOps engineer, and a trainer for the Linux operating system/Unix shell scripting. Get the latest tutorials on SysAdmin, Linux/Unix and open source topics via RSS/XML feed or weekly email newsletter.

Related Tutorials

Your support makes a big difference:

I have a small favor to ask. More people are reading the nixCraft. Many of you block advertising which is your right, and advertising revenues are not sufficient to cover my operating costs. So you can see why I need to ask for your help. The nixCraft takes a lot of my time and hard work to produce. If everyone who reads nixCraft, who likes it, helps fund it, my future would be more secure. You can donate as little as $1 to support nixCraft:

21 comment

There is really no need to use idle, the python shell — ipython under linux is way better than idle, it has both terminal and graphical(QT) versions.

I saw a little spelling mistake on the line: idle – This Debian or Ubunut

источник

Начало работы с Python 3: установка Python >

Всем привет. Данной статьёй мы хотели бы ознаменовать начало цикла уроков посвящённых языку программирования Python 3.

Небольшое описание

Немного расскажем о самом языке:

Python — мощный высокоуровневый язык программирования общего назначения, применяемый во многих сферах, от WEB программирования до математических вычислений.

Читайте также:  Установка адаптера на дисковый тормоз

В качестве преимуществ можно отметить следующие вещи:

  • простоту синтаксиса
  • красоту кода
  • большую востребованность на рынке

В данной же статье я объясню, как установить Python 3 на операционные системы, такие как: Windows, Linux и даже Android.

Начнём пожалуй с Windows, как с самой популярной ОС.

Установка Python на Windows:

Скачивание Python IDLE:

Официальная среда разработки Python 3 абсолютно бесплатна, а потому скачаем её с официального сайта.
Для этого нам нужно:

  1. Зайти на офф. сайт Python вот сюда.
  2. Выбрать вашу операционную систему (зависит от разрядности вашей версии Windows) и способ установки (лично я скачиваю готовый инсталлер, однако есть возможность установки с одновременным скачиванием).
  3. Собственно скачиваем небольшой установщик.

Установка:

  1. Откройте python-3.5.1.exe (название может незначительно отличаться).
  2. При возникновении вопросов со стороны Windows разрешите работу установщика.
  3. Далее следуйте инструкциям установщика.

Установка Python на Linux:

Теперь инструкция по установке на Linux:

  1. Откройте терминал.
  2. Для начала введите:

Часто в дистрибутивы Linux уже включён Python.

Если на выходе вы получили нечто на подобии этого:

Значит Python у вас уже есть и устанавливать его не нужно.
Иначе введите следующее для установки:

Вы можете так же установить IDLE или пользоваться своим любимым редактором.
Для установки IDLE введите в терминале:

Однако, например в Linux Mint и Ubuntu такого пакета нет и там нужно вводить:

Установка на Android:

Самая простая инструкция на сегодня. Мы будем устанавливать бесплатную среду QPython 3.

  1. Найдите в Google Play или пройдите по ссылке(Google Play) QPython 3.
  2. Установите 🙂

Таким образом мы сделали большой шаг в мир Python 3.

В следующих уроках мы рассмотрим Python 3 поближе и постепенно, пройдя его от корки до корки, научимся на нём программировать. А сейчас давайте проверим установленную среду.

Проверяем на работоспособность

Для того, чтобы узнать, работает ли у вас Python, сделайте следующие:

  1. Откройте Python 3 (в Windows и Linux введите в консоли python и python3 соответственно, в Android просто откройте Qpython3 -> Console) .
  2. Введите в консоль следующею строку:

Если на выход вы получили «Hello Python!», то поздравляю вы все правильно сделали.
Теперь можно поэксперементировать. Попробуйте ввести например:

Посмотрите что выйдет 🙂
Спасибо за внимание. До скорой встречи!

Поделиться ссылкой:

Добавить комментарий Отменить ответ

Здравствуйте.
Очень полезная и интересная статья!
Спасибо Вам за эту информацию.

источник

Install Python3 and >

In this article, I will show you how to install Python 3.6 and Python 3.7 in case you don’t have it installed. Let’s get started.

Installing Python 3

First update the package repository cache with the following command:

The package repository cache should be updated.

Installing Python 3.6:

Now to install Python 3.6, run the following command:

As you can see from the screenshot below, Python 3.6 is already installed as I said.

Installing Python 3.7:

To install Python 3.7 (still in beta at the time of this writing), run the following command:

Press y and then press .

Python 3.7 should be installed.

You can run the following command to verify whether Python 3.7 is working:

As you can see, it’s working.

Installing Python 3 IDLE for Developing Python Program

Python 3 IDLE is a graphical program for writing python 3 programs and test them. It is beginner friendly. You can always start writing Python 3 code with Python 3 IDLE. It is lightweight and has nice syntax highlighting ability.

Читайте также:  Установка педалей на полюстровском

Python 3 IDLE is available in the official package repository of Ubuntu 18.04 LTS.

For Python 3.6:

To install Python 3 IDLE for Python 3.6, run the following command:

Press y and then press to continue.

For Python 3.7:

To install Python 3 IDLE for Python 3.7, run the following command:

Using IDLE to Develop a Python 3 Program

Now that you have Python 3 IDLE installed, you can go to the Application Menu and search for Python 3 IDLE.

You should see the following icon as marked in the screenshot below, click on it.

You should see the following window. This is a Python 3.6 shell where you can execute python codes, one line at a time. It is good for testing very simple codes or logics before putting it to your Python 3 source code file.

Now to go to the graphical editor, click on File and you should see the following menu. From here you can click on Open… to open an existing Python 3 source code file in the graphical editor.

NOTE: You can also press + o to open an existing Python 3 source file in the graphical editor.

Or you can click on New File… to create a new file and open it in the graphical editor.

NOTE: You can also press + n to create a new file and open it in the graphical editor.

I created a new file, and when you do, it should look something like this. This is the graphical code editor.

Once you write some code in it, save it somewhere on your filesystem. To save the file, click on File and then click on Save as shown in the screenshot below.

NOTE: You can also save the file by pressing + s.

Now let’s write our very first Python 3 program and save it as hello.py somewhere on your filesystem.

To run the program, click on Run and then click on Run Module. You can also press F5 to run the program.

As you can see, the correct output is displayed on the console.

Customizing Python 3 IDLE

You can go to Options and then Configure IDLE to go to the configuration window of Python 3 IDLE.

Settings window should open as you can see in the screenshot below. From the Fonts/Tabs tab, you can change your IDLE font, font size, the default indentation width.

From the Highlights tab, you can change the Color Scheme or Theme of IDLE. By default, IDLE Classic is set. You can also choose IDLE Dark and IDLE New as you can see in the marked section of the screenshot below.

Once you’re done, click on OK. The changes should be applied.

IDLE Dark theme:

That’s how you install Python 3 and start learning Python 3 on Ubuntu 18.04 LTS. Thanks for reading this article.

источник

Добавить комментарий

Adblock
detector