Skip to Content
Perl To Python Migration
book

Perl To Python Migration

by Martin C. Brown
November 2001
Beginner
320 pages
5h 53m
English
Pearson Business
Content preview from Perl To Python Migration

EXECUTION FROM A FILE

Most Python scripts will be executed from a file. Python scripts are written just like Perl with a standard editor – we don't need a special environment or application to create the files. Line termination is significant, since Python relies on the line termination to identify the end of a statement, but Python is flexible enough to support Windows, MacOS, or Unix line endings under the corresponding platforms. However, if you want to exchange the script between platforms you must convert the line endings – you cannot use a Windows text script under MacOS for example.

Unlike Perl, Python doesn't distinguish quite so clearly between a “script” and a “module.” All Python source can potentially be used as a module and imported ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Perl in a Nutshell

Perl in a Nutshell

Nathan Patwardhan, Ellen Siever, Stephen Spainhour
Perl by Example

Perl by Example

Ellie Quigley
Perl Hacks

Perl Hacks

Chromatic, Damian Conway, Curtis Ovid Poe, Curtis (Ovid) Poe

Publisher Resources

ISBN: 0201734885Purchase book