I've installed numpy on Ubuntu 12.04 with
sudo apt-get install python3-numpy.
Everything seems to go OK, yet when I try to use it I get this error:
Python 3.3.3 (default, Dec 9 2013, 08:33:48)
[GCC 4.6.3] on linux
Type help, copyright, credits or license for more information.
import
On 14-02-27 05:40 PM, eryksun wrote:
On Thu, Feb 27, 2014 at 5:11 PM, Danny Yoo d...@hashcollision.org wrote:
You mentioned you're using Ubuntu 12.04. But the version of Python 3
in that Ubuntu is Python 3.1:
http://packages.ubuntu.com/lucid/python/python3
12.04 (precise), not 10.04
On 14-02-09 05:37 PM, Altrius wrote:
Hi,
I’m completely new to programming in general and everything I have read so
far has pointed me to Python.
I’ll put this another way: All I know is that a programming language is
a medium for a human to tell a computer what to do.
After that I’m
On 14-02-08 12:55 AM, james campbell wrote:
header_bin = header_hex.decode('hex')
AttributeError: 'str' object has no attribute 'decode'
What I understand is that you are trying to decode 'hex', which is a
string. The interpreter is telling you that strings cannot be decoded.
I do not know
On 14-02-02 01:16 PM, Kodiak Firesmith wrote:
Pycharm is nice for bigger projects (since tou can collapse any section);
but it's crazy resource intensive. For Linux Gedit can be made very nice
I prefer Geany as it will run my code with a click of the mouse.
for python, and of course vim in
On 14-02-01 08:20 PM, Steven D'Aprano wrote:
On Sat, Feb 01, 2014 at 06:41:10PM +, Ian D wrote:
Hi
Is it better to use python 3 as a newcomer who isn't really going to
be writing any software as such just using it for learning?
Yes, you should use Python 3, with one proviso: many
Not very elegant, but it'll work. I don't suppose there is a
function for determining the number of digits after the decimal, is it?
It looks like you are trying to avoid rounding errors in decimal arithmetic.
You might be interested in Python's decimal.Decimal type then.
That's right, I
Hello,
I wish to fill a list called years[] with a hundred lists called
year1900[], year1901[], year1902[], ..., year1999[]. That is too much
typing of course. Any way of doing this in a loop? I've tried stuff like
(year + str(1900)) = [0,0] but nothing works.
Any solution?
Thank you,
PierreD.
On 13-12-31 04:09 PM, Keith Winston wrote:
Hi PierreD, I think if you iterate over your strings with something like
this, it will do what you want, if I understand correctly (snum is your
string number, like 123,321):
fnum = float(snum.replace(,, .)
keith: rank beginner, take everything
Hi,
I'm trying to convert a list of strings to float. Unfortunately the
numbers are written with a decimal comma instead of a decimal point.
What is the best way to replace these commas with decimal points? Do I
need to write a function that will iterate over every alphanumeric,
replace the comma
On 13-12-20 05:59 AM, Paradox wrote:
On 12/19/2013 10:46 PM, Keith Winston wrote:
I did this sequence of commands:
sudo add-apt-repository ppa:menulibre-dev/devel
sudo apt-get update
sudo apt-get install menulibre
But at the end of the update I got:
W: Failed to fetch
On 13-12-08 10:57 PM, Reuben wrote:
Can you try importing the module '_tkinter'
On 09-Dec-2013 6:43 AM, pierre dagenais eq...@ncf.ca wrote:
Hi,
I'm running Ubuntu 10.04 and I've installed python 3.3.3 from the
tarball at http://python.org/ftp/python/3.3.3/Python-3.3.3.tar.xz
Here
On 13-12-09 03:14 AM, eryksun wrote:
On Sun, Dec 8, 2013 at 2:36 PM, pierre dagenais eq...@ncf.ca wrote:
I'm running Ubuntu 10.04 and I've installed python 3.3.3 from the
tarball at http://python.org/ftp/python/3.3.3/Python-3.3.3.tar.xz
Here is the error I get when trying to run tkinter
Hi,
I'm running Ubuntu 10.04 and I've installed python 3.3.3 from the
tarball at http://python.org/ftp/python/3.3.3/Python-3.3.3.tar.xz
Here is the error I get when trying to run tkinter.
pierre@Sprint:~$ python3.3
Python 3.3.3 (default, Dec 2 2013, 11:10:53)
[GCC 4.6.3] on linux
Type help,
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
Hi,
I'm running python 3.2 on Ubuntu 11.04 and have a problem with httplib2.
I'm not sure if it's my ignorance or a bug in the code.
This code works:
#! /usr/bin/python3.2
import urllib.request
sock = urllib.request.urlopen(file:///home/pierre/bookmarks.html)
htmlSource = sock.read()
On 11-04-23 06:58 PM, pierre dagenais wrote:
The following code works as expected with python version 2.6.5, but
with version 3.1.2 I get the following error:
pierre:/MyCode/mesProjets$ py3 test.py
Traceback (most recent call last):
File test.py, line 3, in module
sock = urllib.urlopen(http
The following code works as expected with python version 2.6.5, but with
version 3.1.2 I get the following error:
pierre:/MyCode/mesProjets$ py3 test.py
Traceback (most recent call last):
File test.py, line 3, in module
sock = urllib.urlopen(http://diveintopython.org/;)
AttributeError:
On 10-09-18 07:39 PM, ALAN GAULD wrote:
It appears that the Tk canvas widget does not support simply
plotting a pixel.
Correct, and I agree it seems odd, but in practice drawing either
lines or
ovals of one-pixel do the equivalent job - albeit a little more slowly.
The primitive obviously
if that works. You might
also have to modify the PATH and PYTHONPATH environments.
If you wish to install python v2.5.2 maybe you need to uninstall v 2.6,
just gessing.
HTH
Pierre
--- On Thu, 10/9/08, Pierre Dagenais [EMAIL PROTECTED] wrote:
From: Pierre Dagenais [EMAIL PROTECTED]
Subject: Re: [Tutor
Matthew Hill wrote:
I am a newly beginning aspiring programmer. I have been learning Blender 3D and I want to use python with it. I downloaded the newest version of python and I tried running it with Blender 2.47. Python would work alone but would not with Blender. I read on a forum that I
Anthony Smith wrote:
This is my first post - I will be brief...
One: I have programmed before - but it has been DECADES...so just a
few simple queries:
1. A brief (but complete) description regarding the use of script
editor (I will be using
command prompt in Windows), as:
Timothy Grant wrote:
On Tue, Sep 30, 2008 at 10:20 PM, Pierre Dagenais
[EMAIL PROTECTED] wrote:
kayla bishop wrote:
I can't figure out how to write a program where you flip a coin 100 times
and it keeps track of how many heads and tails you flipped but it has to be
random. Can you
Timothy Grant wrote:
On Tue, Sep 30, 2008 at 9:01 PM, Pierre Dagenais [EMAIL PROTECTED] wrote:
Timothy Grant wrote:
On Tue, Sep 30, 2008 at 12:58 PM, Pierre Dagenais
[EMAIL PROTECTED] wrote:
The file test.py is in I:\Python25\MyCode,
if I enter:
C:\Python25\MyCode\python25
If you're right about having to give the full path, and I suspect you
are, Then this means that python knows to search the currennt working
directory for the file to execute, but nowhere else.
Correct, just like every other program.
If you run notepad foo.txt notepad will open a new foo.txt
kayla bishop wrote:
ok i imported the random module and set it up with a 2... i can't get it to loop correctly to where it keeps going until the total of heads and tails is 100 Date: Wed, 1 Oct 2008 00:18:51 -0400 From: [EMAIL PROTECTED] CC: tutor@python.org Subject: Re: [Tutor] (no subject)
The file test.py is in I:\Python25\MyCode,
if I enter:
C:\Python25\MyCode\python25 test.py at the DOS prompt, everything
works as I would expect.
However when I enter the same command from any other directory I get
this error:
C:\python test.py
python: can't open file 'test.py' :
W W wrote:
On Tue, Sep 30, 2008 at 2:58 PM, Pierre Dagenais [EMAIL PROTECTED]wrote:
The file test.py is in I:\Python25\MyCode,
if I enter:
C:\Python25\MyCode\python25 test.py at the DOS prompt, everything works
as I would expect.
However when I enter the same command from any other
Timothy Grant wrote:
On Tue, Sep 30, 2008 at 12:58 PM, Pierre Dagenais
[EMAIL PROTECTED] wrote:
The file test.py is in I:\Python25\MyCode,
if I enter:
C:\Python25\MyCode\python25 test.py at the DOS prompt, everything works as
I would expect.
However when I enter the same command from any
kayla bishop wrote:
I can't figure out how to write a program where you flip a coin 100 times and
it keeps track of how many heads and tails you flipped but it has to be random.
Can you please help
_
Get more out of the Web. Learn
kayla bishop wrote:
I can't figure out how to write a program where you flip a coin 100 times and
it keeps track of how many heads and tails you flipped but it has to be random.
Can you please help
_
Get more out of the Web. Learn
Peter Petto wrote:
I'm about to try some Python programming for drawing simple geometric
pictures (for math classes I teach) and was hoping to get some advice
that will send me off in the best direction.
I want to write programs that can draw figures with commands akin to
point(x,y) to draw
32 matches
Mail list logo