Fabio Zadrozny wrote:
I agree that python code is usually smaller... but what you did is too
unfair (the code below would be more suitable for the comparrison).
python:
print %10.2f % 10
java:
System.out.println(String.format(%10.2f, 10.0));
Though String.format() is new in Java 1.5 so
Kent Johnson wrote:
Fabio Zadrozny wrote:
I agree that python code is usually smaller... but what you did is too
unfair (the code below would be more suitable for the comparrison).
python:
print %10.2f % 10
java:
System.out.println(String.format(%10.2f, 10.0));
Though
Any tips, stories, recommendations, and/or experiences are most
welcome.
Just one suggestion, read the article Things You Should Never Do, Part
I first (
http://www.joelonsoftware.com/articles/fog69.html). Quoting
from the article:
(Netscape made) the *single worst strategic mistake*
Giovanni Bajo wrote:
Also Python code is pretty bare-metal, so that
file.write or socket.write go to the syscall immediately. Try that in Java and
you'll find 30 layers of complex abstractions for doubtful benefits and
obvious
slowness.
+1 QOTW
(I'd recommend the whole post but it might be
John M. Gabriele wrote:
[EMAIL PROTECTED] wrote:
But once it is
there, Python is a good choice for web apps. Java is slow
Slow? They're both dynamic languages, but Java is statically
typed (with less work to do at runtime). For long-running processes,
I'd guess that Java bytecode executes
John M. Gabriele wrote:
But once it is
there, Python is a good choice for web apps. Java is slow
Slow? They're both dynamic languages, but Java is statically
typed (with less work to do at runtime). For long-running processes,
I'd guess that Java bytecode executes faster than Python
[EMAIL PROTECTED] wrote:
I've got a fairly substantial webapp written in Java (plus Tomcat,
Hibernate, Struts, JSP, MySQL) that is a bit of a bear to work with. I
didn't write it. Much of it is only very sparsely documented (if at
all). No design docs anywhere. It's a large webapp with many
Shalabh Chaturvedi wrote:
[EMAIL PROTECTED] wrote:
A class-to-class and method-to-method rewrite will give some but likely
not the full benefit of moving to Python. A redesign might be necessary
- making it more 'Pythonic' in the process. In my experience, many cruft
classes that exist
of toolkits: CherryPy,
Cheetah, SQLObject, all behind Apache2. Has anyone seen performance
issues with Python webapps?
Could one reasonably expect to have an easier time with maintainence
and future modifications with using Python over Java?
Any tips, stories, recommendations, and/or experiences
To replace a large framework you will probably need a framework. Take a
look at http://www.djangoproject.com or http://www.turbogears.org. They
both use some of the tools you mention but operate on a higher level.
I find Python fairly easy to maintain. Unfortunatly, I do not find it
easy to take
be better to use the previous webapp
as a *model* to learn from, rather than to directly translate
code from Java to Python.
But once it is
there, Python is a good choice for web apps. Java is slow
Slow? They're both dynamic languages, but Java is statically
typed (with less work to do at runtime
Hello
I just start programing in Python.
I've got a qestion, how translate the example code writen in Java to
Python??
public class ConnectionManager {
public ConnectionManager() {
super();
}
public void sendAgent(Agent anAgent, WorkplaceAddress anAddress) {
}
}
bye
[EMAIL PROTECTED] wrote:
Hello
I just start programing in Python.
I've got a qestion, how translate the example code writen in Java to
Python??
public class ConnectionManager {
public ConnectionManager() {
super();
}
public void sendAgent(Agent anAgent, WorkplaceAddress
Jacques Daussy wrote:
Hello
How can I transfert information between a JAVA application and a
python script application. I can't use jython because, I must use
python interpreter.I think to socket or semaphore, but can I use it
on Windows plateform ?
Try XML-RPC (a simple implementation of
Hello
How can I transfert information between a JAVA application and a python
script application. I can't use jython because, I must use python
interpreter.I think to socket or semaphore, but can I use it on Windows
plateform ?
thanks a lot
jack
--
Jacques Daussy wrote:
Hello
How can I transfert information between a JAVA application and a python
script application. I can't use jython because, I must use python
interpreter.I think to socket or semaphore, but can I use it on Windows
plateform ?
Jython has an interpreter and Windows has
it. If its not standard, but tehre is a Java way to use it, Again jpype
can be your friend.
If you can tell us more about the nature of each program (Python and
Java) we may be better able to help you.
--
Steve Menard
Maintainer of http://jpype.sourceforge.net
--
http
101 - 117 of 117 matches
Mail list logo