Questions tagged as 'python'

1
answer

Limit items in a dictionary

I'm trying to do data analysis from a self-authored search, the files are already tabbed in .xlsx format. I use openpyxl. My intention at this point is to get participants' status + their opinion and play in a dictionary. The problem...
asked by 28.04.2018 / 12:23
1
answer

Sort as typed (python)

I have a problem with a problem that would be as follows, the problem asks to sort the numbers in the order that you typed them and then do the reverse order, someone can give me a light, the code is more or less this: p> ps: is not in list....
asked by 22.04.2018 / 00:42
1
answer

tkinter locking in function

To do a mini-programinha to be used in the work / study hours style the pomodoro method. I made it very simple, quick, but when I press to start, the program locks exactly the time that was put and only comes back when everything is finished, to...
asked by 25.04.2018 / 06:51
1
answer

Button rounded tkinter

Is there any way to round the ends of the button? Or even leave it as a circumference? Like this for example:     
asked by 25.04.2018 / 06:23
1
answer

What does this -j8 mean?

I'm learning how to set up a server and I came across this -j8 command. I found nowhere an explanation of why this command. Could someone help me understand what he does? Thanks in advance     
asked by 25.04.2018 / 04:50
0
answers

vector manipulation, for structure and variable storage

import math deg2rad = math.pi/180 rad2deg = 1/deg2rad #Cutting conditions Adc = 1 #axial depth of cut [mm] fpt = 1/1000 #feed per tooth [mm/tooth] phi_st = 0 #starting angle [rad] phi_ex = 180*de...
asked by 28.04.2018 / 18:12
1
answer

Turning this readable code into Python 3

Hello, I wanted to know how to make this legible code for Python 3 ' import urllib proxy = {'http': 'http://myproxy:port'} print ("Using HTTP proxy %s" % proxy['http']) urllib.urlopen('https://google.com', proxies=proxy).read() f = urllib.urlo...
asked by 29.04.2018 / 01:30
1
answer

Update a value within a function

I'm starting in Python and need help to create the following function: ESQUERDA = -1 DIREITA = 1 CANHAO = 'A' EXPLOSAO = '*' def moveCanhao(direcao, matriz): ''' int, (matriz) -> bool Recebe um inteiro com a direção (valores definid...
asked by 29.04.2018 / 17:46
0
answers

Bottom of the transparent button on tkinter

I have some buttons with an image and they have a standard gray background that I can not leave transaparente. The goal is to leave only the image of the button and behind it has the background of the window (which is a label). How do I make the...
asked by 21.04.2018 / 09:42
0
answers

detect button pressed python

Does anyone know of any library that recognizes the mouse button pressed but out of the application? I need to create a macro with right mouse button detection.     
asked by 26.04.2018 / 14:04