- 论坛徽章:
- 2
|
Python
is a programming language which has come a long way in a relatively short time. My main interest is the interface to the
PostgreSQL
database. I use
Perl
as part of several websites (including this one,
FreshPorts
and
FreshSource
). I am now investigating Python to see how I can use it in similar areas.
Installing Python
As always, I am using the
ports tree
to install.
cd /usr/ports/lang/python
make install
Hello world!
In keeping with tradition, here my first simple python program:
#! /usr/bin/env python
print "Hello world!" Running that first program is pretty simple:
$ python pg-python
Hello world!
$
What could be easier?!
Connecting to PostgreSQL
As always, I am using the
ports tree
to install.
cd /usr/ports/lang/python
make install
本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/4206/showart_523353.html |
|