Native code performance of J tends to be better than ruby and python. Python tends to have more C libraries and those tend to be faster than J, though J could probably bind to the same libraries. Python also has some JIT compiling tricks to speed it up.
I'm sure that there is a J benchmark that beats a poorly/simply designed C solution, but compiled languages have a significant performance opportunity. In terms of large programs, I don't know of anything larger than JDB. Lines of code are misleading because no one ever counts the J engine or other languages support libraries, and an equivalent J program might have 1/10th the LOC as other languages. Ruby has better language manipulation tools than Python, and J has even better tools than Ruby. 3!:1 will load and store any data quickly. ". apply ~ 5!:0 are forms of eval 5!:5 will give a representation of code or data that can be recreated through later eval Gerunds are lists of verbs/functions that can be manipulated. scripts and explicit functions can be tokenized and replaced. ;: will parse a J sentence into all of its components. ;. can be used to easily process text tables into code or data structures. Overall, I'd say that the power of doing so much in a single line of code is the key advantage of J. If you can do a lot in one line, you can do (and learn) a lot within the repl. ----- Original Message ----- From: Gautam Goel <[email protected]> To: [email protected] Cc: Sent: Wednesday, October 2, 2013 8:03:03 PM Subject: [Jprogramming] J Performance Hi all, I'm a J newbie, and I'm curious about its performance. I've seen statements that J has "very high performance", but I haven't seen actual benchmarks to back that up. How does J compare to languages like C (which are known to be very fast) or Python (which, being interpreted, are usually much slower)? Also, I haven't seen any large (> 10KLOC) programs in J. Does someone have a link to a J repo hosting a significant project? Thanks! -- Cheers, Gautam C. Goel ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
