15,181 Topics

Member Avatar for
Member Avatar for user45949219

I've got a program that is designed to access a nested list and then print values from a certain column in each sublist. My problem being, I don't know how to edit this to provide more freedom with what values I wish to print out. This is how it looks …

Member Avatar for TrustyTony
0
191
Member Avatar for Ismatus3

Hello , When i call a window from the main one , how to hide this one , after calling the second , and define it as a main window , this is the code of the two windows : def InterfaceDeps(): global interf1 interf1 = Toplevel() interf1.geometry("500x400") interf1.title(' Base …

Member Avatar for Ismatus3
0
137
Member Avatar for in_xx

Hi, I am creating a GUI using wxPython. The first window involves making a box with attributes such as title (Big Font Text, results from a file that i will be reading in, want an arrow that changes position depending on results. So think of it like a progress bar. …

Member Avatar for in_xx
0
157
Member Avatar for clouds_n_things

I'm working on re-writing a 2 decade old python program, but I'm hitting a 'resource busy' error when executing. Does anybody have any ideas? The program is below, and the output is below that. Thanks! from scapy.all import * import optparse print "\n--Example format is -s (controller IP: 172.0.0.0), -S(spoof …

0
119
Member Avatar for TempoGnome

Hi! I've been making this game for fun and have run into a few problems, a friend recommended me to ask you guys for help. I have three problems: 1. The player doesn't recongnize when it's not on a platform and because of this it won't fall down. I've narrowed …

Member Avatar for zjtpjs4
0
348
Member Avatar for christopher.north.520125

Ok, literally my first day of learning Python. I am working my own way through Python Programming for the Absolute Beginner and am encountering my first glitch. I downloaded 3.3.1 and am just starting to play around. When I run my program in the Python Shell it works as it …

Member Avatar for vegaseat
0
114
Member Avatar for jellybean21

Hi Guys, I urgently need help with this python project I'm really stuck with it, finding it very confusing at this stage. If anyone could offer me any help I'd really appreciate it!! Heres the question- Data mining is the process of sorting through large amounts of data and picking …

Member Avatar for TrustyTony
0
230
Member Avatar for dusto

Ok, so my program's input is the number of days someone worked. They earn .02 a day. Each day they work after the first, their pay doubles...(.04, .08, .16....) my code below displays the days worked and the money earned each day. I think i did it the hard way …

Member Avatar for woooee
0
123
Member Avatar for Necrozze

Im doing this game for school and it's supposed to be finished real soon and then of course al the problems start coming up, the game now crashes, sometimes after a few seconds and sometimes directly on start. Don't really know why, a thought is that its doing to much …

Member Avatar for Necrozze
0
384
Member Avatar for laver68xo

I'm trying to take a file that looks like this: >taxon1 ACCGTGGATC CCTATTGATT GGATATTATC >taxon2 TTCATATGTA GGATTTCATA GATGGCCCCC And get it to look like this taxon1 ACCGTGGATCCCTATTGATTGGATATTATC I'm using a python script, so far this is what I have: #!/usr/bin/python import sys if len(sys.argv) < 2: print "usage: finalmyscript.py infile.txt" …

Member Avatar for HiHe
0
201
Member Avatar for ddannieellee
Member Avatar for nouth

this time I have only one textfile and I want to remove all duplicate lines so that each and every single line in it is unique unto itself. with open("textfile") as w: for line in w: W = line with open("textfile") as d: c = 0 for line in d: …

Member Avatar for TrustyTony
0
360
Member Avatar for otengkwaku

class Frame(Widget): def __init__(self, master=None, cnf={}, **kw): what is the meaning of **kw in this function, and what does it represent?

Member Avatar for dashing.adamhughes
0
683
Member Avatar for jon92

hello, before people start saying what have i tried, i have not got a clue where to start if i'm honest with you and was wondering if someone could point me in the right direction. i need to create an application which stores information about people(age,name etc),should also be able …

Member Avatar for jon92
0
215
Member Avatar for lizaron

I have a data set like this data=[{u'a': u'D', u'b': 100.0, u'c': 201L, u'd': datetime.datetime(2007, 12, 29, 0, 0), u'e': datetime.datetime(2008, 1, 1, 6, 27, 41)},{u'a': u'W', u'b': 100.0, u'c': 201L, u'd': datetime.datetime(2007, 12, 29, 0, 0), u'e': datetime.datetime(2008, 2, 4, 6, 27, 41)},{u'a': u'W', u'b': 100.0, u'c': 202L, u'd': …

Member Avatar for zjtpjs4
0
270
Member Avatar for mkweska

Hello all! I was able to make a program that writes random numbers to a file depending on how many the user requests. I now need to write a program that read those numbers...prints them... then at the end adds all the numbers from each line together and adds them. …

Member Avatar for snippsat
0
172
Member Avatar for mkweska

Ok thank you in advance for any help! The problem: Write a program that asks the user for the name of a file. The program should display the contents of the file with each line preceded with a line number followed by a colon. The line numbering should start at …

Member Avatar for snippsat
0
474
Member Avatar for Ismatus3

Hello , I am asking about how to create a cickable Area in a Tkinter windows , or if i can make a label Clickable ? this is how the labels are defined : for z in rows: distligne = 15 + distligne a = (z[0].strip(),z[1].strip(),z[2].strip()) print z[0] print a …

Member Avatar for Ismatus3
0
290
Member Avatar for nouth

textfileA = one word per line textfileB = multiple words per line textfileC = words that I have manually found already if words from textfileA also exist in textfileB, I need to replace the words in textfileB with "error" and write the replaced words from textfileB to new lines in …

Member Avatar for nouth
0
324
Member Avatar for Ismatus3

Hello , I am asking about houw to get a hand form of the mouse when it is over a "Label" , this Label is Clickable and defined like this : def callback(event): print "clicked at", event.x, event.y Interface1() lab1dep = Label(interf1, text="Departement Informatique" ,bg = "blue" ,font=("times",12, "bold"), fg …

Member Avatar for Ismatus3
0
228
Member Avatar for vegaseat

A simple test of PySide's QFileDialog widget and its method getOpenFileNames. Use method getOpenFileName if you want just one file name.

3
3K
Member Avatar for rwe0

Has anyone installed tkinter 8.6 on windows ? There is a known bug in filedialog.askopenfilenames which properly returns a tuple of file pathnames under linux, but returns a string under windows. Typical windows return string (should be tuple): C:/testdir/AnotherFile.txt {C:/testdir/This is file with spaces.txt} {C:/testdir/z_last-file test.txt} I'm curious if tkinter …

Member Avatar for vegaseat
1
393
Member Avatar for Faith.Moraa

Hello Team, I've been having a wierd problem with 2 of my scripts and I now know the problem was in my if statements. code=sys.argv[1] phone=sys.argv[2] message=sys.argv[3] if code == 949: servId='62000001760' elif code == 947: servId='62000001840' else: servId='90928' print servId I run this script as: sudo python printserv.py 949 …

Member Avatar for Schol-R-LEA
0
141
Member Avatar for dusto

Ok, so i have the loop that creates the shape below, but instead of spaces, it has solid # signs. I can't figure out how to just get the design I showed below. Where am I going wrong in my code? NUM_STEPS = 6 def main(): for r in range(NUM_STEPS): …

Member Avatar for TrustyTony
0
255
Member Avatar for nexy

How could I pass value entered by user, using tkinter’s Entry to another object? I manage to print it, but couldn’t sent it further… Here are parts of the code: def novo_vreme(): vreme1 = Vreme() root1 = Toplevel(root) root1.title("Vreme") naziv = "Vreme" L1 = Label(root1, text="Zadržavanje: ") L1.place(x=10, y=30) E1 …

Member Avatar for nexy
0
3K
Member Avatar for jhon1987

Hi, Actually I am developing an application in python in which I want a feature by which the application can detect whether any name is male or female name. I did Google search on this, but could not find any algorithm/code by which I can do it. So finally I …

Member Avatar for David1123
0
1K
Member Avatar for jaMT

hi there! is it possible to writte a python program that transfer a sentence in the form of SVO (Subject Verb Object) into the form of SOV (Subject Object Verb)? Example: input: John eat bread output:John bread eat the sentence may be a complex sentence.

Member Avatar for tony75
0
143
Member Avatar for welshly_2010

I am trying to find the max flow of a flow network and the final pattern of the network. But the program is giving me 1 answer and when i try and do it on paper i get a different answer, not sure if one is right or both is …

0
130
Member Avatar for otengkwaku

my question is, how do i use python to check a web site to see if it has an rss feed link and return that link

Member Avatar for slate
0
139
Member Avatar for asim.poptani

**I am Proggraming in python however i have come to a slight glich which i cannot solve! The issue is that when it prints out in a text files it only prints one line of the whole ouput! Otherwise it works! Please i need help to make this work! ** …

Member Avatar for woooee
0
266

The End.