> dollarize(1234567.8901) returns-> $1,234,567,89
>:
> amount = raw_input("Enter an amount: ")
> dollar_amount = dollarize(amount)
> print dollar_amount
the solution you're creating is *slightly* different than the original
spec in the problem (Exercise 13-3). the argument to dollarize() is
s
On: Friday, June 20, 2008 11:47 PM
Kent Johnson Wrote:
On Fri, Jun 20, 2008 at 5:47 PM, FT <[EMAIL PROTECTED]> wrote:
>I would like to know how a file can be open for a stream event?
What is a stream event?
>I ask this question because of the SAPI 5 save a wave file and the only
> way t
"FT" <[EMAIL PROTECTED]> wrote
Caveat: I know nothing about MS SAPI.
The following code illustrates how to speak a text file
in a specific voice in Visual Basic. This example assumes
a text file (ttstemp.txt) containing the text to be spoken
already exists. ISpeechVoice.SpeakStream is used here
Alan Gauld Wrote:
"FT" <[EMAIL PROTECTED]> wrote
Caveat: I know nothing about MS SAPI.
> The following code illustrates how to speak a text file
> in a specific voice in Visual Basic. This example
Notice this says nothing about writing to a file.
> Dim FileName As String
> Dim FileStream As N
Alan,
This is what I wrote in python. The onlyu thing I did not do is a
declaration of a filestream as the VB example does. I get no errors, just
the Speak method just speaks. The saved file has no data, 0 Bytes.
Now the note they mentioned was the True flag and I inserted that.
import S
"FT" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
Alan,
This is what I wrote in python.
file4tts = open('test.wav', 'w', True)
av.AudioOutputStream = file4tts
av.Speak( "Hello World!", ASYNC)
file4tts.close
You need parentheses after close. Otherwise you are
evaluating th
Alan Gauld Wrote:
"FT" <[EMAIL PROTECTED]> wrote
Caveat: I know nothing about MS SAPI.
> The following code illustrates how to speak a text file
> in a specific voice in Visual Basic. This example assumes
> a text file (ttstemp.txt) containing the text to be spoken
> already exists. ISpeechVoic
I would like to capture information from a multi-player internet game in order
to tabulate player statistics. Specifically, I need information from a chat
box within the main play window.
Using the win32 extension (win32gui module: EnumWindows, EnumChildWIndows) I
can obtain a handle to the ch
"Mike Meisner" <[EMAIL PROTECTED]> wrote i
obtain a handle to the chat box. At that point, I don't see any
apparent win32 functions to expose the methods available in
the chat box and, thereby, extract the chat text information I need.
It depends on the exact type of the dialog box.
You can
I've been writing a simple Tkinter interface to one of my programs.
But it looks rather bad on OS X leopard. I was wondering why that was
the case, since it seemed to take up at least some GUI elements (like
button styles). I then came upon the following page:
http://developer.apple.com/unix/toolki
On Sat, Jun 21, 2008 at 5:55 PM, Shrutarshi Basu
<[EMAIL PROTECTED]> wrote:
> I've been writing a simple Tkinter interface to one of my programs.
> But it looks rather bad on OS X leopard. I was wondering why that was
> the case, since it seemed to take up at least some GUI elements (like
> button
Shrutarshi Basu wrote:
I've been writing a simple Tkinter interface to one of my programs.
But it looks rather bad on OS X leopard. I was wondering why that was
the case, since it seemed to take up at least some GUI elements (like
button styles). I then came upon the following page:
http://develo
I'm trying to create a library for the Last.fm webservice[1] and the
first thing I created was a class for the Profile Information.[2] Is
this the proper way of creating it? Is this useful to another programmer?
import urllib
import xml.etree.ElementTree as ET
from BeautifulSoup import BeautifulSt
Martin Walsh wrote:
> def addcommas(f):
> """
> This amounts to reversing everything left
> of the decimal, grouping by 3s, joining
> with commas, reversing and reassembling.
> """
> # assumes type(f) == float
> left, right = ('%0.2f' % f).split('.')
> rleft = [left[::-1][i:i+3] fo
14 matches
Mail list logo