Questions tagged as 'python-3.x'

0
answers

Update a single selected record with Tkinter y, Psycopg2 [closed]

I already managed to update with (Psycopg2-Tkinter). But he does it on all records, as I do to apply only to the selected record. Button(self.edit_wind, text='Actualizar', command=lambda: self.edit_records(nombre=new_nombre.get(...
asked by 21.12.2018 / 23:01
0
answers

Create Python Agenda

I'm creating an agenda where contacts can be added, and then I show them, but when I give them the option to show me the contact, they just show me one and they do not show me all they keep def e2(): contactos = [] class clsContacto ()...
asked by 12.11.2018 / 06:36
1
answer

if the variable is less than ship, generate another random number - python

This exercise is a simulation of a ship arrival system playing with random numbers. Initially, a random number is run to know how many ships arrive during the day. immediately another is generated to see how many ships from which they arrived ca...
asked by 28.10.2018 / 20:20
1
answer

I need help with recursive functions

I have a task that I do not understand how to start, they ask me to tell how many ways I can climb a staircase of N steps eg: pepito can climb 1 or 2 steps in how many ways can climb a staircase of 4 steps, to which I would have to show on scree...
asked by 26.10.2018 / 00:34
3
answers

Extract the value of two indicators

I am new to python and I am taking my first steps. It turns out that I have a file of thousands of rows. The content of the string that contains each row can be of two classes (I leave the capture of both types of string) and is determi...
asked by 13.11.2018 / 14:36
1
answer

Error installing flask-mysql

I am new using python3 and I want you to help me because when you insert the command sudo pip3 install flask-mysqldb the following error occurs     
asked by 16.10.2018 / 21:10
6
answers

Read Chains Python

I need to obtain values that are contained in a string of type str separated by a "," and that when I find the comma, save that value in a new variable for example, I have the string: 10.90,500,56.99 and I want to save the values in a new...
asked by 31.10.2018 / 08:32
0
answers

Improve the speed by creating dynamic columns in a Dataframe

I am creating a Dataframe with the following information: import numpy as np import pandas as pd from time import time start_time = time() columns = 60 Data = pd.DataFrame(np.random.randint(low=0, high=10, size=(700000, 3)), columns=['a', '...
asked by 08.10.2018 / 22:33
1
answer

Problem with pandas.DataFrame.cumsum function

I have the following dataframe in python: month = [1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,1,2,3,4] active = [1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1] data1 = [1709.1,3869.7,4230.4,4656.9,48566.0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,...
asked by 27.09.2018 / 17:14
0
answers

Help with cycles for python

I'm doing a tour of a database in Firebase using for cycles for a school exercise: This is the cycle that I occupy to be able to go through the database: from firebse_login import * fecha = "2018-09" lista_mañana_r = [] l...
asked by 24.09.2018 / 18:15