15,190 Topics
![]() | |
I have NO IDEA how to use Python. Best answer if you write the full program! Please help me! I will be forever grateful! Accept / Reject Monte Carlo Part I: Goal: Write a python program that will: 1. define a function for a specific probability density function f(x), 2. … | |
Assuming that every person has a National ID number, I am trying to check if the Entered number is a valid ID number, under these conditions: 1. ID number must be of 10 digits length. 2. If ID length is greater than/equal to 8 and less than 10 digits, add … | |
on linux i have been using pwd to get the file owner, but how do i do for Windows in python 2.6 since pwd module is supported in linux only..? | |
i have downloaded and installed from this [page](http://sourceforge.net/projects/pywin32/) but still when I import any of the modules[win32api, win32security, win32con] i get import error, please help me if I am not downloading the right version | |
I installed the new **pillow 2.0** on windows 7 python 3.3 using one of the installers with no problems. Apparently that installer provides the jpeg support necessary for Vegaseat's program (link below). However, I am having some kind of trouble getting the jpeg support to work on Ubuntu. After my … | |
Hello all...this is stumping me...it keeps returning a repetition of num ten times rather than multplying by 10...Which way can I fix this? def main(): num = input('Please enter a number: ') print(times_ten(num)) def times_ten(num): return 10 * num main() Thanks!!! | |
Hey, please how can i logically sort for numbers in a list list = [10, 5, 2, 7, 20] without the sort() using only if statements and for loops and no while loop. | |
Simple code to show you how to display an image from a Web URL using the Tkinter Python GUI toolkit, the Python Image Library (PIL) and the data_stream created with io.BytesIO(). | |
Hello , the problem i'm facing is how to insert a cliquable image in a frame , i show the code : def InterfaceDeps(): global interf0 interf0 = Toplevel() interf0.geometry("500x400") interf0.title(' Test Data') f1 = Frame(interf0, bg="blue", width=500, height=500) f1.pack( fill=X, expand=0) ####### Image ############# imageinfo = Image.open("C:/Documents and Settings/Administrateur/Bureau/Python_tests/nvprojet/Info1.jpg") … | |
Hi Im working with the old exercise in python and I need help please. The goal of this exercise is to extract information and statistical data from a log file. You can use the logfile generated by the linux kernel. You should write a python code which gives the following … | |
I am trying to remove a column from PyQt4 implementation of table model , however I am not able to figure it out what I am doing wrong def removeColumns(self, position, columns, parent = QtCore.QModelIndex()): self.beginRemoveColumns(parent, position, position + columns - 1) #Do removing here rowCount = len(self.__colors) for i … | |
given an audio signal x, there are a number of simple effects that can be implemented on such a file. we are to implement base dumps and treble dumps given piecewise functions relating to each | |
http://pastebin.com/4eCJUP8d The comment "zipCode, city and state variables are of type string, declare them to be lists if you want to use the append() method on them. Do not use where which is a reserved word in Python. I don't see a loop in the readRecord() method that iterates through … | |
A newb programmer here I have a project involving pedestrian simulation I'm planning to use libpedsim.dll in python with Ctypes but so far I cannot make the functions working Can anyone point out how to make use of this DLL? This is the class documentation: http://pedsim.silmaril.org/documentation/libpedsim/latest/classPed_1_1Tscene.html This is the link … | |
Guys how do I install WxPython in Ubuntu? I tried following the directions here: But to no avail.... [URL="http://wiki.wxpython.org/InstallingOnUbuntuOrDebian"]http://wiki.wxpython.org/InstallingOnUbuntuOrDebian[/URL] Is there an easier way to do this? | |
I wrote the code as below its extracting all tabular data by splitting. Now i want to extract the last column(Values) data by removing Text in the middle of the table. import re f_read = open('filename','r') f_write=open('filename','w') str='CEN/4' for line in f_read: m=re.search(str,line) if m: for line in f_read: # … | |
Dear friends, I need again your help for a new challenge ;) I have a number of files with 5 columns of values (comma separated). I would like to find a way to the values in the first 2 columns and compare them with the first 2 columns of the … | |
Hello, I'm currently working on a homework problem that requires me to create a dictionary from a .txt file that contains some of the worst cars ever made. The file looks something like this: 1958 MGA Twin Cam 1958 Zunndapp Janus 1961 Amphicar 1961 Corvair 1966 Peel Trident 1970 AMC … | |
Can there be a conflict between two different version of python ? I have a program that needs access to Python 2.6, I have a environment variable setup, so the program that needs access to a subfolder of the Python 2.6 installation is suppose to access via this environment variable; … | |
Quick question on stripping, I'm executing a simple program, but whenever I try and run it in Terminal, it strips all wrong. The error it puts out is below. It iterates [+]Trying: admin/admin for the first line, but wont repeat it for the rest of the lines, as well as … | |
Hi - I am working through learn python the hard way and I am trying to practice using nosetests command with the "game" I created. The problem when I run nosetests it works fine until it is time to test a class that has raw_input in it, then it just … | |
Hi Guys, I am trying to modify an xml string on the fly. I will enter a sample XML string and the code should generate modified xml.I have exploied it later. xml = xml = '''<FixedPage xmlns="http://schemas.microsoft.com/xps/2005/06" xmlns:x="http://schemas.microsoft.com/xps/2005/06/resourcedictionary-key" xml:lang="en-us" Width="793.92" Height="1122.24"><FixedPage.Resources><ResourceDictionary><LinearGradientBrush x:Key="b0" StartPoint="0,0" EndPoint="0,1122.24" ColorInterpolationMode="SRgbLinearInterpolation" MappingMode="Absolute" SpreadMethod="Pad"><LinearGradientBrush.GradientStops><GradientStop Color="#FFFFFFFF" Offset="0" /><GradientStop … | |
Did anyone have an idea about block a connection to a specific website.I want to choose www.examle.com page to block and the program to block me to get in this site?I thougth first to detect in what website i visit and i don't have any idea how to make ot … | |
I have a project due for my programming class on Friday and im hopelessly stuck on this problem if anyone could help me please, it would be great >The question is: Write a function that takes 4 arguments (integer, integer, picture, string). This function should be able to be used … | |
Using Ubuntu 12.10 have been using python 2.7 and python 3.2 successfully. 2.7 is my default interpreter. Now, after installing python 3.3 it looks like the python3.3 version of "/usr/include/python3.3" was not installed (as it is for "usr/include/python3.2" . I have already done "sudo apt-get install python-dev" . I discovered … | |
I'm looking for fellow programmers that write in python, and maybe have skills in HTML/CSS to bounce some ideas off of, and generally just form a little python programming group. Let me know! :D | |
So, I have a quick question about a small password cracking program that I wrote. The syntax seems to be fine, but when run at the command terminal (I'm on a mac), the program doesn't really DO anything. I'll click "run in terminal" or I'll already have the terminal window … | |
I am new to python and will like to solve ordinary differential equation in Python. How do I differentitae the following equation(1st order and 2nd order). I wish to differentiate C wrt Q C = (Q**3)-15*(Q**2)+(93*Q)+100 | |
Hi I wonder if somthing wrong with this script? I get this resuly in my linux ./accessdll.py : No such file or directory #!/usr/bin/env python from subprocess import Popen, PIPE from re import split from sys import stdout class Proc(object): ''' Data structure for a processes . The class properties … | |
Hi i have linux mint os i have instaled python..and also wxpython and now i cannot run my application fron anywhere how i can add a path that i can run my python scripts from anywhere in my pc.. |
The End.