14,946 Topics

Member Avatar for
Member Avatar for simplysach

in my i.t lesson we were intoduced to 'raspberry pi' within 'Python' and for my homework i have to explain what we did in the lesson. It says i have to include what 'input' is when coding a programme. Please help and reply as soon as possible and keep in …

Member Avatar for Schol-R-LEA
0
321
Member Avatar for arty.net

I have written some code just to practice verbosity in python. Verbosity is embedded by means of the ArgumentParser module....however, I'd also like to write the stdout to file also when verbosity is disabled : #!/usr/bin/python from optparse import OptionParser from argparse import ArgumentParser import sys def printable1(): print "1" …

0
185
Member Avatar for raju_6

Hello I am looking for a way to open command prompt of my remote windows machine with python code. could somebody help me with that ? Thank you.

Member Avatar for raju_6
0
1K
Member Avatar for rajeshwari_ib

Hi all, i am new to python how to store image into database blob using python please help me for this its urgent

Member Avatar for Gribouillis
0
2K
Member Avatar for ben.juarez.773

I have scoured the internet, but to no avail. Perhaps someone can point me in the right direction about the following for Classes in pygame: 1. Item One: I would like to make random enemy movements within each class or subclass. 2. Item Two: I would like to change the …

0
78
Member Avatar for trade19

Hi I think this topic is beyond my lame python abbilities. I hope the program can run, it is writen by using error messages until it worked. I am using python 33. I am trying to learn info on adding leading zeros to the output.(File & Windows) I am not …

Member Avatar for trade19
0
256
Member Avatar for ram619

Hello, I want to duplicate a list in python. The way I want is, I need two list with same content pointing to different memory Location. What I tried is Dup_List = Original_List[:] , but lookes like even this is making both list point to same memory location. Both the …

Member Avatar for vegaseat
0
168
Member Avatar for mary jane_1

Hi! I already have separate codes that can make a call from hyperterminal using AT commands and a script that can send SMS. My problem is I need to make a code that can make a call and while a call is in progress, the code will be able to …

0
42
Member Avatar for trade19

Hi I am having a problem with the "nextz" part "Click Here to see the new winning number." I want to kill this button after it shows the winning number. but it prints another number every time I click the button. how can i click once show once. Thanks for …

Member Avatar for trade19
0
173
Member Avatar for brett.warren.1612

I getting an error when I try to run this function here: def get_char_out(prompt=None): while True: try: return str(raw_input(prompt + ' ')) break except ValueError: print '\nInvaild input' print get_char_out('String, please') I keep getting this error here: String, please Traceback (most recent call last): File "main.py", line 11, in get_char_out('String, …

Member Avatar for brett.warren.1612
0
212
Member Avatar for cilla

I've been really interested in Django lately, so I came here to check out the scene on the forums, only to find there's no Python/Django subforum in Web Development. Where can I come on here for support regarding web development with Django?

Member Avatar for JorgeM
0
277
Member Avatar for christopherbe11

I have this code:: name_list=[] name1=print(input("what is your name: ")) name_list.append(name1) print(name_list) it returns Jon [NONE] If i input a name jon. Why does it not append to list please?

Member Avatar for christopherbe11
0
155
Member Avatar for rbyrd

Can anyone tell me how to get rid of the white boxes around the buttons? I want the boxes to be blue so the buttons appear on an entirely blue panel at the bottom of the ffame. I'm using OSX 10.6.8 and Python 2.7. Thanks in advance. from Tkinter import …

Member Avatar for rbyrd
0
264
Member Avatar for ben.juarez.773

Hello, I'm a beginner using Python 3.3.3. I'm working on a little text-based rpg using the skills I've learned thus far, but am wondering what the problem is with my code. When I enter the first input response, like 1, everything seems to be fine, but when I enter 2, …

Member Avatar for ben.juarez.773
0
181
Member Avatar for MrNoobieCoder

import random guessesTaken = 0 my_name = input("Hello, What is your name? ") difficulty = input("Well, "+ my_name + ". What dificulty would you like ? easy medium or hard? " if difficulty == easy number = random.randint (1,20) print ("Okay, " + my_name + ". I am thinking of …

Member Avatar for Kai_Chang
0
6K
Member Avatar for Thomas_16

Write the definition of a function power_to , which receives two parameters. The first is a double and the second is an int . The function returns a double . If the second parameter is negative, the function returns zero. Otherwise it returns the value of the first parameter raised …

Member Avatar for Gribouillis
0
66
Member Avatar for yogeetha

We need to ensure that the connection is secure. The python version we use is 2.6. Trying to call prot_p() explicitly errors out. How do we ensure that the connection is secure. >>> from M2Crypto import ftpslib >>> ftps = ftpslib.FTP_TLS(host) >>> ftps.login(username, password) '230 User logged in.' >>> ftps.prot_p() …

0
164
Member Avatar for trade19

Hi I need help using the variable mytik as a counter in the GUI "app" If you run this code mytik stays at 1,2,3,4 or 5 as entered but when I need it for a counter in the next GUI window it no longer has the value of say "1,2,3,4,or …

Member Avatar for woooee
0
116
Member Avatar for birinci2012

def isPrime(num,div=2): if(num==div): return True elif(num % div == 0): return False else: return isPrime(num,div+1)

Member Avatar for slate
0
995
Member Avatar for arunpawar

I am trying to extend a script that opens a web browser and opens URL. I want to use that script and make it to search google for particular query. That's all. Here's the code that I got. I would appreciate, if you know how to extend it for the …

Member Avatar for arunpawar
0
256
Member Avatar for giancan

Hi there, I have a set of values and I know that some of them are good and some are not... but I cannot find the ratio. I know it souns strange but let me explain. Here is the list of values 37 - 16 - good 21 - 12 …

Member Avatar for Gribouillis
0
233
Member Avatar for matmunn14

I'm trying to write a small program to loop through a list of words and find the numeric order of the letters in the string, e.g. HELLO will return 21345 (I don't want to double up numbers) and PROSPER will be 3527416. I'm having trouble thinking of a way I …

Member Avatar for matmunn14
0
309
Member Avatar for trade19

Hi can anyone help me i am using python 3 and i am new here. I want to know how i can make these random numbers, example: 4 11 17 21 44 - 20 show up, like the example. The problem is the last #20 shows up below the others. …

Member Avatar for Gribouillis
0
174
Member Avatar for crebz

Am trying to get a function call but i cant get it to print. Please help here. This is the code: def foo(): name = input ('>>').lower().split() for item in name: if name == foo: print ('foo here!') else: bar() def bar(): name = input ('>>').lower().split() for item in name: …

Member Avatar for crebz
0
243
Member Avatar for bnn678

Not usually one to have to do this, but I cannot find the problem with my code. Yes, this is a project Euler problem. Any tips or suggestions help. My code works by getting the location of each number, excluding the first numbers as it has to be predefined, and …

Member Avatar for scudzilla
0
188
Member Avatar for G_S

I have this: dic = {'ál':1, 'él':2} string = "ÉL" number=dic[string.lower()] and it's giving me a KeyError. I realize then that 'ÉL'.lower() is giving me 'Él', i.e. it is not affecting the É at all because some weird Python 2.x encoding issue. Can somebody help me please? I can't tell …

Member Avatar for G_S
0
1K
Member Avatar for bnn678

a1 = 1 a2 = 2 a3 = 3 ....... a10000 = 10000 So, I want to create a function that will autoassign names to numbers. In the the code above, for x in range (desired range): a(quantity of x) = x how do i get my code to call …

Member Avatar for Gribouillis
0
210
Member Avatar for brittany.nelson.526

I am having a problem with a loan calculator that I am building. It keeps telling me that the interest_rate variable it referenced before assignment. I'm fairly new to python and was wondering if anyone had any ideas as to what is wrong with my code. Any help would be …

Member Avatar for TrustyTony
0
318
Member Avatar for novice20

hi all... how to find the localhost ip address in python [B]import socket socket.gethostbyname(socket.gethostname())[/B] gives me 127.0.0.1 instead of my ip address any help...........

Member Avatar for Suraj_2
0
906
Member Avatar for karmstrong

I'm wondering if anyone has any experiencing getting a python application to authenticate with google docs. I'm not sure how to begin. Goal: To update a google docs spreadsheet based of a CSV file on my local machine. Currently my google account is set for two factor authentication. Perhaps this …

Member Avatar for dashing.adamhughes
0
249

The End.