Programa de Análisis de Riot -- python campo con api campo con tkinter camp codereview Relacionados El problema

Riot Analysis Program


4
vote

problema

Español

Esta es una aplicación de análisis de alboroto. Recopile datos utilizando la API de Riot y muestra a los usuarios varios datos. Nada demasiado profundo.

archivo gui : este archivo es el archivo GUI para el programa. Tengo la clase que convierte al resto de los marcos del programa. Después de hacer clic en el botón para buscar un Summoner, recopilará datos de otra clase en el juego y devolverá una lista de 5 datos con cada un tipo diferente (matar, muerte, asistencia, visión, victorias). Tengo dos variables globales que no quiero usar en la clase DataCollected, no puedo encontrar una manera de no usarlas.

  import tkinter as tk from tkinter import font as tkfont from getId import id_collected from games import Game from wins import is_player_good   class RiotApp(tk.Tk):      def __init__(self, *args, **kwargs):         tk.Tk.__init__(self, *args, **kwargs)         self.title_font = tkfont.Font(family='Helvetica', size=18, weight="bold", slant="italic")         container = tk.Frame(self)         container.pack(side="top", fill="both", expand=True)         container.grid_rowconfigure(0, weight=1)         container.grid_columnconfigure(0, weight=1)         self.frames = {}         for F in (StartPage, MenuPage, KillPage, DeathPage, CsPage, HonestPage):             page_name = F.__name__             frame = F(parent=container, controller=self)             self.frames[page_name] = frame             frame.grid(row=0, column=0, sticky="nsew")          self.show_frame("StartPage")      def show_frame(self, page_name):         frame = self.frames[page_name]         frame.tkraise()  class StartPage(tk.Frame):      def __init__(self, parent, controller):              tk.Frame.__init__(self, parent)         c = DataCollected()         self.controller = controller         self.label = tk.Label(self, text="Enter summoner name:", width = 20, font = ("bold", 20))         self.label.place(x=90,y=53)         self.entry = tk.Entry(self)         self.entry.place(x=190,y=130)                  self.button = tk.Button(self, text="Search",width = 20, bg = 'brown', fg = 'white',                             command=lambda: data_collected(self,controller))         self.button.place(x=180,y=200)          def data_collected(self,controller):                      name = self.entry.get()             Key = '****************************************'             a = id_collected(name, Key)             if a != 'NO':                 controller.show_frame("MenuPage")                 c.collect_data(name, Key)             else:                 controller.show_frame('StartPage')  class DataCollected():          def collect_data(self, name, Key):          num_games = 20         game = Game()         accId = id_collected(name, Key)         game_list = game.find_game_ids(accId, Key, num_games)         global stat_list         stat_list = game.game_data(game_list, Key, name, num_games)         global honest         honest = is_player_good(stat_list[5])  class MenuPage(tk.Frame,DataCollected):      def __init__(self, parent, controller):         tk.Frame.__init__(self, parent)         self.controller = controller         label = tk.Label(self, text="Main Menu", font=controller.title_font)         label.place(x=180,y=50)         button = tk.Button(self, text="Kill Average",width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("KillPage")).place(x=180,y=100)         button = tk.Button(self, text="Death Average",width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("DeathPage")).place(x=180,y=150)         button = tk.Button(self, text="Cs Average",width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("CsPage")).place(x=180,y=200)         button = tk.Button(self, text="Honest Truth",width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("HonestPage")).place(x=180,y=250)         button = tk.Button(self, text="Back",width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("StartPage")).place(x=180,y=300)  class KillPage(tk.Frame, DataCollected):          def __init__(self, parent, controller):         tk.Frame.__init__(self, parent)         self.controller = controller         self.label = tk.Label(self, text = 'Kills Average', width=20,font=("bold", 20))         self.label.place(x=90, y=100)         self.label1 = tk.Label(self, text = ' ', width=20,font=("bold", 20))         self.label1.place(x=90, y=150)         self.label1.after(1000, self.refresh_label)         self.button = tk.Button(self, text = "Back", width = 20, bg = 'brown', fg = 'white',                         command=lambda: controller.show_frame("MenuPage")).place(x=180,y=300)      def refresh_label(self):         self.label1.configure(text = stat_list[1])         self.label1.after(1000,self.refresh_label)  class DeathPage(tk.Frame):      def __init__(self, parent, controller):         tk.Frame.__init__(self, parent)         self.controller = controller         self.label = tk.Label(self, text = 'Deaths Average', width=20,font=("bold", 20))         self.label.place(x=90, y=100)         self.label2 = tk.Label(self, text="", width=20,font=("bold", 20))         self.label2.place(x=90, y=150)         self.label2.after(1000, self.refresh_label)         self.button = tk.Button(self, text="Back", width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("MenuPage")).place(x=180,y=300)      def refresh_label(self):         self.label2.configure(text = stat_list[0])         self.label2.after(1000,self.refresh_label)  class CsPage(tk.Frame):      def __init__(self, parent, controller):         tk.Frame.__init__(self, parent)         self.controller = controller         self.label = tk.Label(self, text = 'Cs Average', width=20,font=("bold", 20))         self.label.place(x=90, y=100)         self.label3 = tk.Label(self, text="", width=20,font=("bold", 20))         self.label3.place(x=90,y=150)         self.label3.after(1000, self.refresh_label)         self.button = tk.Button(self, text="Back", width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("MenuPage")).place(x=180,y=300)      def refresh_label(self):         self.label3.configure(text = stat_list[4])         self.label3.after(1000,self.refresh_label)  class HonestPage(tk.Frame):      def __init__(self, parent, controller):         tk.Frame.__init__(self, parent)         self.controller = controller         self.label = tk.Label(self, text = 'Honest Truth', width=20,font=("bold", 20))         self.label.place(x=90, y=100)         self.label4 = tk.Label(self, text = " ", width=20,font=("bold", 20))         self.label4.place(x=90,y=150)         self.label4.after(1000, self.refresh_label())         self.button = tk.Button(self, text = "Back", width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("MenuPage")).place(x=180,y=300)      def refresh_label(self):         self.label4.configure(text = honest)         self.label4.after(1000,self.refresh_label)  if __name__ == "__main__":      stat_list = [1,1,1,1,1,1,1]     honest = ' '     root = RiotApp()     root.geometry("500x500")     root.mainloop()   

Archivo de juego : este archivo comience por recopilar las identificaciones del juego y usar las ID de juego para recopilar las estadísticas de dicho Slumoner en cada uno de los 20 juegos. Luego lo devuelve al archivo GUI.

  import requests  class Game:      def find_game_ids(self, accId, key, num_games):         i = 0         GAMEID = []         num_games = 20         url_match_list = ('https://na1.api.riotgames.com/lol/match/v4/matchlists/by-account/' + (accId) + '?queue=420&endIndex=20&api_key=' + (key))         response2 = requests.get(url_match_list)         # Adding 20 games into the list         while num_games > 0:             GAMEID.append('https://na1.api.riotgames.com/lol/match/v4/matches/'+str(response2.json()['matches'][i]['gameId']) + '?api_key=' + (key))             i = i + 1             num_games = num_games - 1          return GAMEID      def game_data(self, game_list, key, sumName, num_games):          wins = []         deaths = []         deaths = []         kills = []         assists = []         visions = []         csTotal = []         # Finding the data of said summoner in each game id         for urls in game_list:             response = requests.get(urls)             resp_json = response.json()             Loop = 0             index = 0             while Loop <= 10:                  if resp_json['participantIdentities'][index]['player']['summonerName'] != sumName:                     Loop = Loop+1                     index = index+1                 elif resp_json['participantIdentities'][index]['player']['summonerName'] == sumName:                      deaths.append(resp_json['participants'][index]['stats']['deaths'])                     kills.append(resp_json['participants'][index]['stats']['kills'])                     assists.append(resp_json['participants'][index]['stats']['assists'])                     visions.append(resp_json['participants'][index]['stats']['visionScore'])                     csTotal.append(resp_json['participants'][index]['stats']['totalMinionsKilled'])                     wins.append(resp_json['participants'][index]['stats']['win'])                      break         # Finding avg of each stat         deaths = sum(deaths)/num_games         kills = sum(kills)/num_games         assists = sum(assists)/num_games         visions = sum(visions)/num_games         csTotal = sum(csTotal)/num_games         wins = sum(wins)/num_games         stat_list = []         stat_list.append(deaths) #0         stat_list.append(kills) #1         stat_list.append(assists) #2         stat_list.append(visions) #3         stat_list.append(csTotal) #4         stat_list.append(wins) #5          return stat_list   

ID de ID : este archivo recopila el ID de Summoner para la clase de juego en el archivo de juego.

  import requests  def id_collected(sumName, key):     # COLLECTING DATA TO BE INSERTING FOR MATCHLIST DATABASE     url = ('https://na1.api.riotgames.com/lol/summoner/v4/summoners/by-name/'+(sumName)+'?api_key='+  (key))     response = requests.get(url)     if response.status_code == 200:         accId = (response.json()['accountId'])         return accId     else:          accId = 'NO'         return accId   

gana el archivo : este archivo usará el 9988776665544336 para determinar si el jugador ha sido bueno en los últimos 20 juegos y devolverá una frase.

  import random   def is_player_good(winlist):      if winlist < 0.33:         message = ['DIS MANE STINKS', 'run while you can', 'I repeat, YOU ARE NOT WINNING THIS', 'I predict a fat L', 'Have fun trying to carry this person', 'He is a walking trash can', 'He needs to find a new game', 'BAD LUCK!!!']         return (random.choice(message))      elif winlist > 0.33 and winlist <= 0.5:         message = ['Losing a bit', 'Not very good', 'He needs lots of help', 'Your back might hurt a little', 'Does not win much']         return (random.choice(message))      elif winlist > 0.5 and winlist <= 0.65:         message = ['He is ight', 'He can win a lil', 'You guys have a decent chance to win', 'Serviceable', 'Should be a dub']         return (random.choice(message))      elif winlist > 0.65:         message = ['DUB!', 'You getting carried', 'His back gonna hurt a bit', 'winner winner chicken dinner', 'Dude wins TOO MUCH', 'You aint even gotta try', 'GODLIKE']         return (random.choice(message))   
Original en ingles

This is a riot analysis app. Collect data using the riot API and shows the user various data. Nothing too in depth.

GUI file - This file is the GUI file for the program. I have the class that make the rest of the frames of the program. After clicking the button to search for a summoner, it will collect data from another class in game and return a list of 5 data's with each being a different type(kill, death, assists, vision, wins). I have two global variable that I don't want to use in DataCollected class, I can't seem to find a way not to use them.

import tkinter as tk from tkinter import font as tkfont from getId import id_collected from games import Game from wins import is_player_good   class RiotApp(tk.Tk):      def __init__(self, *args, **kwargs):         tk.Tk.__init__(self, *args, **kwargs)         self.title_font = tkfont.Font(family='Helvetica', size=18, weight="bold", slant="italic")         container = tk.Frame(self)         container.pack(side="top", fill="both", expand=True)         container.grid_rowconfigure(0, weight=1)         container.grid_columnconfigure(0, weight=1)         self.frames = {}         for F in (StartPage, MenuPage, KillPage, DeathPage, CsPage, HonestPage):             page_name = F.__name__             frame = F(parent=container, controller=self)             self.frames[page_name] = frame             frame.grid(row=0, column=0, sticky="nsew")          self.show_frame("StartPage")      def show_frame(self, page_name):         frame = self.frames[page_name]         frame.tkraise()  class StartPage(tk.Frame):      def __init__(self, parent, controller):              tk.Frame.__init__(self, parent)         c = DataCollected()         self.controller = controller         self.label = tk.Label(self, text="Enter summoner name:", width = 20, font = ("bold", 20))         self.label.place(x=90,y=53)         self.entry = tk.Entry(self)         self.entry.place(x=190,y=130)                  self.button = tk.Button(self, text="Search",width = 20, bg = 'brown', fg = 'white',                             command=lambda: data_collected(self,controller))         self.button.place(x=180,y=200)          def data_collected(self,controller):                      name = self.entry.get()             Key = '****************************************'             a = id_collected(name, Key)             if a != 'NO':                 controller.show_frame("MenuPage")                 c.collect_data(name, Key)             else:                 controller.show_frame('StartPage')  class DataCollected():          def collect_data(self, name, Key):          num_games = 20         game = Game()         accId = id_collected(name, Key)         game_list = game.find_game_ids(accId, Key, num_games)         global stat_list         stat_list = game.game_data(game_list, Key, name, num_games)         global honest         honest = is_player_good(stat_list[5])  class MenuPage(tk.Frame,DataCollected):      def __init__(self, parent, controller):         tk.Frame.__init__(self, parent)         self.controller = controller         label = tk.Label(self, text="Main Menu", font=controller.title_font)         label.place(x=180,y=50)         button = tk.Button(self, text="Kill Average",width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("KillPage")).place(x=180,y=100)         button = tk.Button(self, text="Death Average",width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("DeathPage")).place(x=180,y=150)         button = tk.Button(self, text="Cs Average",width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("CsPage")).place(x=180,y=200)         button = tk.Button(self, text="Honest Truth",width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("HonestPage")).place(x=180,y=250)         button = tk.Button(self, text="Back",width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("StartPage")).place(x=180,y=300)  class KillPage(tk.Frame, DataCollected):          def __init__(self, parent, controller):         tk.Frame.__init__(self, parent)         self.controller = controller         self.label = tk.Label(self, text = 'Kills Average', width=20,font=("bold", 20))         self.label.place(x=90, y=100)         self.label1 = tk.Label(self, text = ' ', width=20,font=("bold", 20))         self.label1.place(x=90, y=150)         self.label1.after(1000, self.refresh_label)         self.button = tk.Button(self, text = "Back", width = 20, bg = 'brown', fg = 'white',                         command=lambda: controller.show_frame("MenuPage")).place(x=180,y=300)      def refresh_label(self):         self.label1.configure(text = stat_list[1])         self.label1.after(1000,self.refresh_label)  class DeathPage(tk.Frame):      def __init__(self, parent, controller):         tk.Frame.__init__(self, parent)         self.controller = controller         self.label = tk.Label(self, text = 'Deaths Average', width=20,font=("bold", 20))         self.label.place(x=90, y=100)         self.label2 = tk.Label(self, text="", width=20,font=("bold", 20))         self.label2.place(x=90, y=150)         self.label2.after(1000, self.refresh_label)         self.button = tk.Button(self, text="Back", width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("MenuPage")).place(x=180,y=300)      def refresh_label(self):         self.label2.configure(text = stat_list[0])         self.label2.after(1000,self.refresh_label)  class CsPage(tk.Frame):      def __init__(self, parent, controller):         tk.Frame.__init__(self, parent)         self.controller = controller         self.label = tk.Label(self, text = 'Cs Average', width=20,font=("bold", 20))         self.label.place(x=90, y=100)         self.label3 = tk.Label(self, text="", width=20,font=("bold", 20))         self.label3.place(x=90,y=150)         self.label3.after(1000, self.refresh_label)         self.button = tk.Button(self, text="Back", width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("MenuPage")).place(x=180,y=300)      def refresh_label(self):         self.label3.configure(text = stat_list[4])         self.label3.after(1000,self.refresh_label)  class HonestPage(tk.Frame):      def __init__(self, parent, controller):         tk.Frame.__init__(self, parent)         self.controller = controller         self.label = tk.Label(self, text = 'Honest Truth', width=20,font=("bold", 20))         self.label.place(x=90, y=100)         self.label4 = tk.Label(self, text = " ", width=20,font=("bold", 20))         self.label4.place(x=90,y=150)         self.label4.after(1000, self.refresh_label())         self.button = tk.Button(self, text = "Back", width = 20, bg = 'brown', fg = 'white',                            command=lambda: controller.show_frame("MenuPage")).place(x=180,y=300)      def refresh_label(self):         self.label4.configure(text = honest)         self.label4.after(1000,self.refresh_label)  if __name__ == "__main__":      stat_list = [1,1,1,1,1,1,1]     honest = ' '     root = RiotApp()     root.geometry("500x500")     root.mainloop() 

Game file - This file start by collecting game ids and using the game ids to collect the stats of said summoner in each of there 20 games. Then returns it to gui file.

import requests  class Game:      def find_game_ids(self, accId, key, num_games):         i = 0         GAMEID = []         num_games = 20         url_match_list = ('https://na1.api.riotgames.com/lol/match/v4/matchlists/by-account/' + (accId) + '?queue=420&endIndex=20&api_key=' + (key))         response2 = requests.get(url_match_list)         # Adding 20 games into the list         while num_games > 0:             GAMEID.append('https://na1.api.riotgames.com/lol/match/v4/matches/'+str(response2.json()['matches'][i]['gameId']) + '?api_key=' + (key))             i = i + 1             num_games = num_games - 1          return GAMEID      def game_data(self, game_list, key, sumName, num_games):          wins = []         deaths = []         deaths = []         kills = []         assists = []         visions = []         csTotal = []         # Finding the data of said summoner in each game id         for urls in game_list:             response = requests.get(urls)             resp_json = response.json()             Loop = 0             index = 0             while Loop <= 10:                  if resp_json['participantIdentities'][index]['player']['summonerName'] != sumName:                     Loop = Loop+1                     index = index+1                 elif resp_json['participantIdentities'][index]['player']['summonerName'] == sumName:                      deaths.append(resp_json['participants'][index]['stats']['deaths'])                     kills.append(resp_json['participants'][index]['stats']['kills'])                     assists.append(resp_json['participants'][index]['stats']['assists'])                     visions.append(resp_json['participants'][index]['stats']['visionScore'])                     csTotal.append(resp_json['participants'][index]['stats']['totalMinionsKilled'])                     wins.append(resp_json['participants'][index]['stats']['win'])                      break         # Finding avg of each stat         deaths = sum(deaths)/num_games         kills = sum(kills)/num_games         assists = sum(assists)/num_games         visions = sum(visions)/num_games         csTotal = sum(csTotal)/num_games         wins = sum(wins)/num_games         stat_list = []         stat_list.append(deaths) #0         stat_list.append(kills) #1         stat_list.append(assists) #2         stat_list.append(visions) #3         stat_list.append(csTotal) #4         stat_list.append(wins) #5          return stat_list 

Get id file - This file collect the summoner id for the Game class in game file.

import requests  def id_collected(sumName, key):     # COLLECTING DATA TO BE INSERTING FOR MATCHLIST DATABASE     url = ('https://na1.api.riotgames.com/lol/summoner/v4/summoners/by-name/'+(sumName)+'?api_key='+  (key))     response = requests.get(url)     if response.status_code == 200:         accId = (response.json()['accountId'])         return accId     else:          accId = 'NO'         return accId 

wins file - This file will use the stat_list[5] to determine whether the player has been good in past 20 games and will return a phrase.

import random   def is_player_good(winlist):      if winlist < 0.33:         message = ['DIS MANE STINKS', 'run while you can', 'I repeat, YOU ARE NOT WINNING THIS', 'I predict a fat L', 'Have fun trying to carry this person', 'He is a walking trash can', 'He needs to find a new game', 'BAD LUCK!!!']         return (random.choice(message))      elif winlist > 0.33 and winlist <= 0.5:         message = ['Losing a bit', 'Not very good', 'He needs lots of help', 'Your back might hurt a little', 'Does not win much']         return (random.choice(message))      elif winlist > 0.5 and winlist <= 0.65:         message = ['He is ight', 'He can win a lil', 'You guys have a decent chance to win', 'Serviceable', 'Should be a dub']         return (random.choice(message))      elif winlist > 0.65:         message = ['DUB!', 'You getting carried', 'His back gonna hurt a bit', 'winner winner chicken dinner', 'Dude wins TOO MUCH', 'You aint even gotta try', 'GODLIKE']         return (random.choice(message)) 
        
     
     

Lista de respuestas

3
 
vote
vote
La mejor respuesta
 

Variables locales

Dado que prisoners0655443360 es una variable local, aunque técnicamente es una referencia a una clase, y las clases se capitalizan, 99887776655443361 debe ser minúscula. Además, merece tener un nombre que no sea una letra. prisoners2 También debe ser minúscula.

Lambdas

esto:

  prisoners3  

no merece ser una lambda. Dado que también está almacenando prisoners4 en prisoners5 , es mejor simplemente hacer un método en la clase para esto, y pasar una referencia unida a ese método para prisoners6 .

Listas sensibles a la posición

  prisoners7  

es un olor a código. Supongo que esta es una lista de estadísticas, donde cada posición en la lista es un tipo diferente de estadística. Esto debe convertirse en una clase, o al menos, una tupla llamada.

Adición en el lugar

  prisoners8  

debe ser

  prisoners9  

Pruebas de rango

  odd_sweets0  

debe ser

  odd_sweets1  

Parens

esto:

  odd_sweets2  

no necesita parentes exteriores y debe eliminarlos.

TYPO?

en odd_sweets3 .

 

Local variables

Since F is a local variable - even though it's technically a reference to a class, and classes are capitalized - F should be lower-case. Also, it deserves to have a name that isn't one letter. Key should also be lower-case.

Lambdas

This:

command=lambda: data_collected(self,controller)) 

does not deserve to be a lambda. Since you're also storing controller on self, it's better to simply make a method on the class for this, and pass a bound reference to that method for command.

Position-sensitive lists

stat_list[5] 

is a code smell. My guess is that this is a list of statistics, where each position in the list is a different kind of statistic. This should be converted to a class, or at the least, a named tuple.

In-place addition

i = i + 1 

should be

i += 1 

Range testing

winlist > 0.33 and winlist <= 0.5 

should be

0.33 < winlist <= 0.5 

Parens

This:

return (random.choice(message)) 

does not need outer parens and should remove them.

Typo?

In He is ight.

 
 
   
   

Relacionados problema

4  Abra una ventana de selección de archivos a la posición más alta de Jupyter Notebook  ( Open a file selection window to top most position from jupyter notebook ) 
Fondo Se me ocurrió esta solución a una pregunta que publiqué en StackOverflow . Utiliza Tkinter para crear una ventana de diálogo de selección de archivos...

5  Python - Juego de Quiz con Tkinter  ( Python quiz game with tkinter ) 
He hecho un pequeño juego de preguntas en Python. Esta fue mi primera experiencia en la programación de GUI en Python con Tkinter. En general, no tengo mucho ...

3  Convertidor binario / decimal / hexagonal usando tkinter  ( Binary decimal hex converter using tkinter ) 
Debatí mucho tiempo y duro antes de publicar esta pregunta, y hice mucho experimentación. Simplemente no puedo resolver una "elegante", de manera concisa de h...

3  Primer programa de Python: Calculadora básica  ( First python program basic calculator ) 
Quiero comenzar a aprender Python por diversión y, por lo tanto, podría profundizar en los proyectos de aprendizaje de la máquina más adelante en el futuro ta...

4  Formulario de entrada de datos simple que escribe datos a texto de texto  ( Simple data entry form that writes data to textfile ) 
Hice un formulario de entrada de datos que escribe cada categoría en un archivo de texto. Como ejemplo, usé categorías regulares, premium y diesel. Cada uno d...

5  Solicitud de Tkinter para administrar las tareas escolares  ( Tkinter application to manage school tasks ) 
Soy un principiante en la programación de la OOP y me pregunto cuál es la mejor manera de poner todas las ventanas y funciones de una aplicación de ventana en...

2  Hacer una lista de la entrada del usuario - Seguimiento  ( Making a list from user input follow up ) 
He realizado los cambios que la gente ha sugerido de mi Pregunta previa . Quiero intentarlo y hacerlo aún más ordenado si es posible. ¿Qué puedo cambiar para...

5  Calculadora de área y volumen  ( Area and volume calculator ) 
Soy un codificador para principiantes, haciéndolo únicamente por diversión, habiendo comenzado a codificar hace unos dos meses con Python. Tengo un punto de t...

4  Hacer una lista de la entrada del usuario  ( Making a list from user input ) 
He escribido un programa que permite al usuario abrir su archivo de texto que se vería algo así: 1 2 3 4 5 6 Luego, le permitiría que el usuario ingres...

5  Generando contraseñas simples y complejas  ( Generating simple and complex passwords ) 
Soy bastante nuevo en Python y me gustaría algunos consejos y críticas en mi estilo / código de formato y lo que puede organizarse mejor. Soy un poco inestabl...




© 2022 respuesta.top Reservados todos los derechos. Centro de preguntas y respuestas reservados todos los derechos