Crummy BS Script

Steven D'Aprano steve at
Sat Oct 2 08:24:08 CEST 2010

On Fri, 01 Oct 2010 21:05:09 -0700, flebber wrote:

> On Oct 2, 9:27 am, MRAB <pyt... at> wrote:
>> On 01/10/2010 23:29, Burton Samograd wrote:>
>> flebber<flebber.c... at>  writes:
>> >> But where is this saving the imported file and under what name?
>> > Looks like samples.csv:
>> >> f = open('samples.csv', 'w')
>> It'll be in the current working directory, which is given by:
>>      os.getcwd()
> So how do I call the output to direct it to file? I can't see which part
> to get.

I don't understand your question. What do you mean "call the output" -- 
you normally don't call the output, you call a function or program to get 
output. The output is already directed to a file, as you were shown -- it 
is written to the file samples.csv in the current directory.

Perhaps if you explain your question more carefully, we might be able to 
help a little more.


More information about the Python-list mailing list