Questions tagged as 'python-3.x'

1
answer

Python: how to edit tag with bs4

I have a html code, well polluted with Style in almost all tags, as well as% unnecessary% tags. How can I use beautifulsoup, to remove only attrs = style in <font><span> and the <p> tags without removing their...
asked by 12.03.2018 / 04:26
1
answer

Delete the last number that I typed

Friends, one more doubt (^^). Look at the following code: Numero = int(input('Digite um Numero')) inteiro = [] inteiro.append(Numero) while Numero>0: Numero = int(input('Digite um Numero')) inteiro.append(Numero) if Numero<0: pri...
asked by 05.03.2018 / 18:02
0
answers

Separate "functions" from "complements" - Python 3

So, I'm doing an application in python 3 which is a terminal, but I do not know how to separate the words, type: Every programming language has a certain "function" before executing the code, such as Python's print . This terminal will hav...
asked by 01.03.2018 / 01:25
1
answer

How to convert a saved string to a .txt file, to an integer?

Example: test = open ('test.txt', 'w') test.write ('6000') test.close () How do I convert the contents of the .txt file to integer in order to be able to do operations with it? if you can not do this, how can I save data without losing it...
asked by 28.02.2018 / 18:02
0
answers

PyCharm IDE on Windows

I have the custom of using PyCharm over GNU / Linux, and by force majeure I will have to use it on Windows. The problem is this: When running the python program through the IDE, a python crawler, the program does not end. It's like you're w...
asked by 28.02.2018 / 15:56
1
answer

A question about python PyAutoGUI?

Is it possible, by chance, to use PyAutoGUI in a browser that is not appearing on the screen? I type a code for PyAutoGUI to work with the coordinates of a specific browser (eg Firefox) while I view other things on the screen ex: see youtube vid...
asked by 27.02.2018 / 14:47
1
answer

Connection Python and pymysql

I am creating a login system and user records. I created a model to do the insertion and in the controller, it validates the information and step for the model to write, however, my model is not working. Here is the connection to the bank d...
asked by 28.02.2018 / 02:09
1
answer

Tkinter, how to update label on canvas?

Hello, I'm trying to build a PivotTable that automatically updates values but I'm not able to update the Labels, I'm using the following code: import tkinter as tk def populate(frame): global widgets widgets={} '''Put in some fa...
asked by 24.02.2018 / 15:49
0
answers

Receiving data from a server in the console

Hello, as I am learning python and I entered this network area and exchange information, I would like to get some questions about the code I created trying to make a console interact with a server. Server Code: import socket import sqlite3...
asked by 20.02.2018 / 05:53
0
answers

Exporting data from mysql to csv

I am trying to export specific data from a bank from a client to csv, I searched the internet and they said I would get using the code below. SELECT * FROM escola INTO OUTFILE '/var/lib/mysql-files/orders.csv' FIELDS TERMINATED BY ',' ENCLOSED...
asked by 16.02.2018 / 13:49