15,175 Topics
| |
If you press any key on your keyboard, this small Tkinter GUI program will tell you which key and what type of key has been pressed. Great for applications where a simple key stroke is required. | |
Hi all, I need to create a program on python that: At the start a 4 sided dice is thrown and a 12 sided dice is thrown to calculate two values for strength and skill the following method is used for each player: - Each attribute is originally set to … | |
The issue i am having using this text to speech is that it start play before a panel is open , how do i get it to play after a panel in wxpython is open import pyttsx3 # initialisation engine = pyttsx3.init() # testing engine.say("Welcome to 24-hour ATM service") engine.say("Thank … | |
| |
Hello people. Sorry for my English, I use google translator .. Please Can anyone convert this code to C # or vb.net? import sys VERSION = 0 SUBVERSION = 2 def usage(): print "[+] WPSpin %d.%d " % (VERSION, SUBVERSION) print "[*] Usage : python WPSpin.py 123456" sys.exit(0) def wps_pin_checksum(pin): … | |
I tried achieving using list index position but that's not the good way of coding, as we will never know which position is the column located. Honestly, I tried to come how to achieve in python in getting correct values for each column but in vain Need help in python … | |
**May I know how to correct the NameError: name 'xx' is not defined ?** import numpy as np import matplotlib.pyplot as plt from sklearn import svm, datasets # import some data to play with iris = datasets.load_iris() X = iris.data[:,[2,3]] y = iris.target def plotSVC(title): # create a mesh to … | |
Hiya, looking for some help on this bit of code: def save(x,y,z): user=x yourinventory=y score=z allinvent=[] allscore=[] with open("Inventory.txt","r+")as inventory: for line in inventory: allinvent.append(line.strip().split(',')) allinvent.append("\n") for line in allinvent: if (line[0]==yourinventory): allinvent.append(yourinventory) allinvent.pop(line[0:8]) print(allinvent) break inventory.append(allinvent) inventory.close I'm currently working on saving things like inventory, and I'm not sure … | |
Parsing Large Numbers Question Hi All, I am writing some simple code to raise a base value to a power then perform some operations on the output. I have included the code I am using now, below ( see end of this message ), also see immediately below what this … | |
Hi, I'm trying to infintley print random numbers. I have the code to print infintley, but not to print a random number (completely random, no pattern). Does anyone have the code to print a list of numbers completely at random? | |
I am trying to build a GUI app for graph plotting where graph can be shown as a slideshow so that the data can be clearly visualised. First I wish to plot a set of data then after a specific time interval next set of data and so on. I … | |
I have four ordinary differential equation written in mathmatica : Simplify[DSolve[{y1'[x] == -0.162y1[x], y2'[x]=-0.148 y2[x]+ 0.055y1[x],y3'[x]==-0.134 y3[x]+ 0.033y1[x]+ 0.039y2[x],y4'[x]==-0.125y4[x]+0.021 y1[x]+0.025y2[x]+ 0.043y3[x], y1[0] == 100,y2[0]==4.76,y3[0]==69.7,y4[0]==0}, {y1[x], y2[x],y3[x],y4[x]}, x]] I am trying to write them in python I have try the following : def n1(y,x): s1 = 0.162131 dydx = -s1 * … | |
I'm trying to create a platformer with tkinter, i've created the character and now i'm trying to create a dynamic background with a biomes system so when the player passes from a biome to another the background changes the image. from tkinter import * from PIL import Image, ImageTk from … | |
Hello, I don't know too many things of programming, I've barely started with some online courses, but am at the very beginning. This is what I need to do: 1. From a folder that contains multiple files I need to copy a particular file. 2. Paste that particular file in … | |
I am trying to implement Connect 4 game using Min-Max as utility to find best possible move.<br><br> The game is played on a 6x7 grid, with six rows and seven columns. . The two players take turns placing pieces on the board: the red player can only place red pieces, … | |
An example showing how to use the wx.media.MediaCtrl() widget to play MIDI, MP3, WAV, AU, AVI and MPG audio and video files. I have only tested it with Windows. If you are very ambitious, you could use a random graphics display with the sound, or tie the slider position to … | |
Hello, I found this code in a thread from about 18 months ago in a post by 'woooee' - [CODE]def func_1(): print " func_1 test" def func_2(): print " func_2 test" def func_3(): print " func_3 test" def func_4(): print " func_4 test" ##---------------------------------------------------------------- ## dictionary = list of function … | |
I've been tasked with this assignment: > In a graphics window, you are to draw an outdoor scene containing a house. > Your drawing should include at least the following shapes: three rectangles, two lines, one circle and one text label > Your picture should not be boring black and … | |
Hello there ! Which python books do you recommend for system programming? | |
Hello everyone, I am a learner, who found this helpful community where one's query is satisfied in so many great ways. I have one such query regarding Recursion. Can anyone help me to know about the effects of Recursion in Python? Does it cause any trouble? | |
**Create a student class which has following functionality:** - Initialise a student with mandatory parameters - Create a student with name, email and phone number - Add a list of subjects based on which class he is - Add a function to calculate his percentage based on marks scored ***I … | |
I couldn't install the tensorflow framework in my laptop.can anyone help me out in installing tensorflow for doing my project on deep learning techniques. | |
Is there any need for overloading operators in python? | |
This short Python code gets the local time from the PC as a formatted string using time.strftime('%H:%M:%S'). The time string is displayed in a label using a larger font. A recursive function checks the time five times per second, and updates the time string, if it has changed. Five times … | |
Hi everyone, i am in need of ideas and want a bit of advise...i want to make a serial port sniffer which will be able to read the data goin in and out of the serial port between two other programs..... im not sure how i will be able to … | |
Hi, I have created a quiz whixh displays an artist and the first letter of their song and the user has to guess the song. However, I need help looping the quiz so it displays another artists if the user has anwered correctly after their first or second guess. Thank … | |
Hello all, I was wondering if I could get some questions answered about how cupons work in the work place. I have an idea which involves creating a very flexible cupon service, but would require knowing the rudiments of how cupons work. The main question I have is how is … | |
HI All! I need to have some help. I have a python function name is abc.py and variable is declared in abc.py, variable name is 'uname'. How can i call variable name 'uname' of abc.py in my batch file name testing.bat and get uname value in my batch testing.bat file? … | |
![code_error.png](/attachments/large/4/0618569524bcc2abec40e81e5691d469.png) I'm relatively new to python, and I'm trying to create a pokemon battle. This error has come up, I've looked up solutions but it hasn't helped me as I can't understand it properly. Please help, I'd like to learn especially since I'm planning on taking IT and computer science … | |
i am here ![Screen_Shot_2018-12-28_at_6_47_38_PM.png](/attachments/large/4/237abffd6067e29aa8bd690c2c1a74ec.png) i want to merge all rowsof 3 rd col so that output looks like... end result should be.... ![Screen_Shot_2018-12-28_at_6_49_34_PM.png](/attachments/large/4/92adfc647020ab9265f7d7248758c82f.png) |
The End.