Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > Does Python compete with Java?

Reply
Thread Tools

Does Python compete with Java?

 
 
=?ISO-8859-1?Q?=22Martin_v=2E_L=F6wis=22?=
Guest
Posts: n/a
 
      04-14-2004
Jakub Fast wrote:
> Is there really no chance this goes into python on an "if you really
> have to do this, be warned, but here are the tools" basis?


Certainly. Write a PEP, and an implementation.

Alternatively, write a different parser front end that converts your
enriched language into standard Python.

Regards,
Martin

 
Reply With Quote
 
 
 
 
Jakub Fast
Guest
Posts: n/a
 
      04-14-2004
> Certainly. Write a PEP, and an implementation.

I cosider myself silenced .

[but then, i'd have trouble filling the "Disadvantages" section in the
PEP...]

> Alternatively, write a different parser front end that converts your
> enriched language into standard Python.


i did think of that .

kuba

 
Reply With Quote
 
 
 
 
Daniel Yoo
Guest
Posts: n/a
 
      04-15-2004
Jakub Fast <(E-Mail Removed)> wrote:

: On quite another note, is it possible to define your own operators in

: learning them actually might turn out useful for whatever they want to
: do in the future -- more useful than, say, prolog) and nothing can beat
: the intuitive appeal of

: S ==> (NP and VP) or VP

: over CFGProduction(S, NP, VP), CFGProduction(S, VP) for specifying your
: simple cfg, dcg or ebnf rules if you're completely new to programming
: and have just been given a programming assignment

Hi Jakub,

You may then want to give your students a prewritten parser that takes
a string like "(NP and VP) or VP" and reproduces the kind of data
structure that you want. John Aycock's SPARK toolkit is a really nice
tool for building such a tool:

http://pages.cpsc.ucalgary.ca/~aycock/spark/


As an example, you may find:

http://hkn.eecs.berkeley.edu/~dyoo/python/propositions/

interesting --- I wrote it a LONG LONG time ago, but it may be useful
for you. It is not production code by a long shot, but may still
serve as a beginning.


Good luck!
 
Reply With Quote
 
Maurice LING
Guest
Posts: n/a
 
      04-15-2004
A. Lloyd Flanagan wrote:
> Dave Benjamin <(E-Mail Removed)> wrote in message news:<(E-Mail Removed)>...
>
>>Over the long term, I think Python's biggest key to success will be that we
>>will still be able to read the programs that we are writing now.

>
>
> No argument here


I don't quite understand, does Python have to compete with Java? In many
cases, the programming language used to write an application almost has
no relevance to the acceptance of the application. Although we thought
(think) that a compiled language is faster, better than an interpreted
language like python, it has some contradictions. I was researching for
an assignment some time back on 2GL and 3GL and the general dogma is
that the lower the language, the faster it should run, but a paper in
ACM digital library showed that a program in Ada can run substantially
faster than one written in assembly.

What I see is that Python and Java can be synergistically linked, for
example, through Jython, can be more constructive than competition...

Maurice
 
Reply With Quote
 
Graham Fawcett
Guest
Posts: n/a
 
      04-15-2004
Jakub Fast <(E-Mail Removed)> wrote in message news:<(E-Mail Removed)>...
> I've been pondering using python+NLTK to teach a computational semantics
> class this summer (precisely because i think the basics of python would
> be easy for the students to learn quickly, and, class aside, that
> learning them actually might turn out useful for whatever they want to
> do in the future -- more useful than, say, prolog) and nothing can beat
> the intuitive appeal of
>
> S ==> (NP and VP) or VP
>
> over CFGProduction(S, NP, VP), CFGProduction(S, VP) for specifying your
> simple cfg, dcg or ebnf rules if you're completely new to programming
> and have just been given a programming assignment


Using a domain-oriented mini-language (parsed from within Python) is a
simple way to "extend" Python syntax.

An new instance of a DgcGrammar class, for example, could represent a
new, empty grammar; it could have an eval() method which could parse a
string of DGC rules to be added to itself: e.g.,

g = DcgGrammar()
g.eval('s --> np,vp. np --> det,n. ...').

Perhaps not what you had in mind; but personally, I think the
separation of syntaxes enforced by the method call is a a benefit. You
get Prolog (kind of) and Python both, without having to force one to
imitate the other.

There are Python tools for generating parsers from EBNF grammars, for
example, which could be used to whip up a domain-language parser in a
jiffy.

And, of course, your students get the added benefit of having the
parser's source code available -- for reuse, Python instruction and
light bedtime reading!

(On another note, I seem to recall there's a Prolog implementation in
Python somehwere; perhaps there's some reusable DGC-related code
there.)

Just two cents,

-- Graham
 
Reply With Quote
 
Peter Hansen
Guest
Posts: n/a
 
      04-15-2004
Maurice LING wrote:
> A. Lloyd Flanagan wrote:
>> Dave Benjamin <(E-Mail Removed)> wrote:
>>> Over the long term, I think Python's biggest key to success will be
>>> that we will still be able to read the programs that we are writing now.

>>
>> No argument here

>
> I don't quite understand, does Python have to compete with Java? In many
> cases, the programming language used to write an application almost has
> no relevance to the acceptance of the application.


That's not the whole picture though. One would also like to be able
to easily find programmers capable of working very effectively with
the language, so that maintenance can be performed, and enhancements,
and new projects using the same language.

This "competition" he's talking about is not really going on in the
users' minds, but in the developers' minds. Imagine how difficult it
would be to get anywhere with projects if there were so many popular
languages that the odds of a given developer knowing your language
were, say, less than 2%...

> What I see is that Python and Java can be synergistically linked, for
> example, through Jython, can be more constructive than competition...


That is yet another of Python's strengths.

-Peter
 
Reply With Quote
 
kk
Guest
Posts: n/a
 
      04-15-2004
That is exactly my point! If I were starting a company that needed a
staff to write custom software or software for sale, I could choose to
use Python as the predominate tool. Assuming this was a rational
decision, and not an emotional one, this could lower my costs by
making programmers more productive, and making maintenance cheaper.
However, if there are no programmers in my area that know Python, how
could I justify that decision? I would have the expense of training
programmers on the job, as well as having a hard time getting
applicants for the job.

Python doesn't have big company dollars behind it like Java and C#,
and some say it never will. It could be argued that the same thing
was said about Linux a few years ago. Now, you can't pick up an IT
rag without reading something about Linux and Open Source.

compete -> as in developer mind-share.

I would hope that someday Python would be a "tool" that "most"
developers would want to have in their "tool box".


Peter Hansen <(E-Mail Removed)> wrote in message news:<(E-Mail Removed)>...
> Maurice LING wrote:
> > A. Lloyd Flanagan wrote:
> >> Dave Benjamin <(E-Mail Removed)> wrote:
> >>> Over the long term, I think Python's biggest key to success will be
> >>> that we will still be able to read the programs that we are writing now.
> >>
> >> No argument here

> >
> > I don't quite understand, does Python have to compete with Java? In many
> > cases, the programming language used to write an application almost has
> > no relevance to the acceptance of the application.

>
> That's not the whole picture though. One would also like to be able
> to easily find programmers capable of working very effectively with
> the language, so that maintenance can be performed, and enhancements,
> and new projects using the same language.
>
> This "competition" he's talking about is not really going on in the
> users' minds, but in the developers' minds. Imagine how difficult it
> would be to get anywhere with projects if there were so many popular
> languages that the odds of a given developer knowing your language
> were, say, less than 2%...
>
> > What I see is that Python and Java can be synergistically linked, for
> > example, through Jython, can be more constructive than competition...

>
> That is yet another of Python's strengths.
>
> -Peter

 
Reply With Quote
 
Peter Hansen
Guest
Posts: n/a
 
      04-15-2004
kk wrote:

> That is exactly my point!


Uh, sorry, but what point? The email address and initials you
are using here ((E-Mail Removed) and kk) have not posted
before in this thread, as far as I can see. So who are you?

-Peter
 
Reply With Quote
 
Maurice LING
Guest
Posts: n/a
 
      04-15-2004
I understand what you are trying to get at. In my mind, the
"competition" between languages had existed since the 1st day I wrote
Hello World in QBasic. Maybe there are two types of computer guys in
this world, those that learn the minimal and those that learn as much as
possible. I think I belong to the latter group even though I'm a
molecular biologist/bioinformaticist by trainings. Simplicity in syntax
is Python's strength to cater for the former group. Another thing that
can be done is to improve the libraries. In this world of 3000
programming languages, what makes Python worth learning?

Personally, I do wish to see that Python AND Java becomes mainstream,
although the latter has. A "marketing" strength which wasn't quite
tapped into is universities. If Python is taught in universities, then
it isn't tough to become mainstream. That's how mysql got so popular, or
at least I think that's how. Python enforces good programming
techniques, such as, readability. Yet, themes as such are taught in C,
perhaps one of the most unreadable language. Trying to debug a badly
indented C program is a horror, not to mention people do write a
recursive function in a single line!!

Maurice

Peter Hansen wrote:
> Maurice LING wrote:
>
>> A. Lloyd Flanagan wrote:
>>
>>> Dave Benjamin <(E-Mail Removed)> wrote:
>>>
>>>> Over the long term, I think Python's biggest key to success will be
>>>> that we will still be able to read the programs that we are writing
>>>> now.
>>>
>>>
>>> No argument here

>>
>>
>> I don't quite understand, does Python have to compete with Java? In
>> many cases, the programming language used to write an application
>> almost has no relevance to the acceptance of the application.

>
>
> That's not the whole picture though. One would also like to be able
> to easily find programmers capable of working very effectively with
> the language, so that maintenance can be performed, and enhancements,
> and new projects using the same language.
>
> This "competition" he's talking about is not really going on in the
> users' minds, but in the developers' minds. Imagine how difficult it
> would be to get anywhere with projects if there were so many popular
> languages that the odds of a given developer knowing your language
> were, say, less than 2%...
>
>> What I see is that Python and Java can be synergistically linked, for
>> example, through Jython, can be more constructive than competition...

>
>
> That is yet another of Python's strengths.
>
> -Peter

 
Reply With Quote
 
Kyler Laird
Guest
Posts: n/a
 
      04-16-2004
I've only caught bits of this thread and I don't really want to address
any one post in particular but I thought a timely example is in order.

I have been needing to get more control over bookmarks in the PDF files
I concatenate. I've tried a bunch of tools but my current favorite is
iText.
http://itext.sourceforge.net/
It's written in Java and I thought I could make some simple mods to the
example concatenation program with my *very* rusty Java skills. Nope.
I spent an afternoon trying to figure out how to do it without any luck.
I gave up.

After I regained some strength, I decided to throw Jython at it. I had
not used Jython for anything more than to verify that it really worked.
Within minutes I was interactively poking my way through iText libraries
with Jython, discovering what I could do. My enhancement was fairly
easy to implement and it reminded me how much less effort it takes to
accomplish things in Python than in Java.

Bottom line...I don't give a hoot about a language "competition." I'm
going to keep using Python because it allows me to accomplish Great
Things. It even lets me do those where C or Java are "required." I
like it.

--kyler
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can Cable (TV) Still Compete? tabernacle2002@hotmail.com DVD Video 2 11-23-2005 01:05 AM
Re: Does Python compete with Java? Jakub Fast Python 2 04-15-2004 02:16 AM
Need programmers? At Colance they compete for your business. M Brian Edwards HTML 0 12-11-2003 09:54 AM
Need programmers? At Colance they compete for your business. g0P Phillip Torres Perl 0 12-02-2003 11:07 AM
Make lenders compete for your loan mixxa zsg Jack Dwyer Python 0 09-07-2003 11:30 AM



Advertisments