Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Java vs. brainfuck vs. Python.

Name: Anonymous 2007-04-24 18:38 ID:oUkHXcjW

http://en.wikipedia.org/wiki/Brainfuck
http://en.wikipedia.org/wiki/Java
http://en.wikipedia.org/wiki/Python_%28programming_language%29

Now that we're all up to speed, discuss the pros and cons of each language, as well as which you believe to be the superior language.

Name: Anonymous 2007-04-24 18:57 ID:DwbH7Sj5

Brainfuck is sadomasachism for geeks.
Python is Haskell for dummies.
Java is for dummies.

Name: Anonymous 2007-04-24 20:24 ID:fgYYp+33

NO EXCEPTIONS

Name: Anonymous 2007-04-24 20:31 ID:qNEckRqU

Java is a useful yet verbose and ugly language. The libraries it has are set out sort of ok, anyway I find it amusing for coursework because at least you emulate functional programming.

Python,
ONE WORD,
 THE FORCED INDENTATION OF CODE,
  THREAD OVER!


brainfuck is a beautifully elegant gem of programming but idiots like >>2 cant appreciate it

and of course, lisp is superior http://www.paulgraham.com/hundred.html

Name: Anonymous 2007-04-24 21:10 ID:2i4Y1DNA

Brainfuck is the only one of those three that's touring-complete.

Name: Anonymous 2007-04-24 21:40 ID:qNEckRqU

>>5
whats touring-complete?

Name: Anonymous 2007-04-24 22:19 ID:i1BM2VAN

>>5 I LOLed.

Name: Anonymous 2007-04-25 2:21 ID:FnUmtpzy

>>6
The correct spelling for turing-complete. The world was wrong and 4chan is always right.

Name: Anonymous 2007-04-25 2:42 ID:WHkU4Y7B

>>8
stop trolling

also, QUACK

Name: Anonymous 2007-04-25 3:34 ID:FnUmtpzy

>>9
stop lying.

Name: Anonymous 2007-04-25 7:36 ID:404aoXXF

Brainfuck is a Turing tarpit, and a Touring tarpit. Only for lulz.

Java is a piece of shit of a language (good syntax, but stupid object model, stupid operators, stupid lack of features such as operator overloading, stupid constraints, stupid static typing) with a piece of shit of an API (extensive and useful, but completely insane, overengineered, ridiculous, full of enterprise-grade best-practices that create synergy between business logic and operative cost). Productivity will suck, and it may very well be even worse than C.

Python is a quite good languge with a feature set similar to that of Ruby and, to a lesser scale, Lisp. It has a clean syntax (good looking save for __, easy to read, forces idiots to indent statement blocks though nothing else) and a powerful object model, and supports structured, OO and functional programming. It comes with an extensive and useful API that's usually simple to use. Get things done very fast, and good execution speed for an interpreted dynamic languge. Also, QUACK.

Name: Anonymous 2007-04-25 8:48 ID:OurY95A9

ECMAScript 4 is better than all of them.

Name: Anonymous 2007-04-25 10:24 ID:XE9ELJVe

>>11
did you say forces idiots to indent..


DID YOU SAY FORCED INDENTAATION OF CODE??

I THINK THREAD IS OVER

also JAVA programmers use a language so fucking verbose they dont mind using  a build system which rqeuires them to write XML files

Name: Anonymous 2007-04-25 10:31 ID:IZnYf7Az

I used to think Java was pretty cool. Now I have to use it all the time for uni projects.. If real programming jobs are like this, I will become an hero.

Name: Anonymous 2007-04-25 11:02 ID:eBsE8c7r

>>14
Yes, real programming jobs are like this.
real programmers do programming for a hobby and not to get paid.

Name: Anonymous 2007-04-25 11:29 ID:x2wGFFqe

>>14
get used to fapping to multi-platform, enterprise-grade, scalable solutions to produce synergy using the industry standards

Name: Anonymous 2007-04-26 6:00 ID:UV3pGa0T

>>15
Truth

Name: Anonymous 2007-04-26 6:08 ID:E2YYEntS

>>14

You'll be pleased to know that not all real programming jobs are Java wankfests. But far too many are.

True story, one of my friends had a mental breakdown from having to program Java every day, for 70+ hours a week (he worked in London in the financial sector, they love long hours there)

Name: Anonymous 2007-04-29 15:53 ID:gSxLSN9T

>>4
GTFO. How can you say Java lets you emulate functional programming? It lets you do object-oriented. You obviously have no idea what functional programming is. Python, on the other hand, is multi-paradigm, and lets you try your hand at functional programming.

Name: Anonymous 2007-04-30 3:43 ID:Mz6NxB8Y

>>19
java.lang.reflectiowned!

Name: Anonymous 2007-04-30 15:49 ID:JLIUaydy

python takes away all your power because it's sad excuse for functional programming is not supported  by Guido van faggot Russo or whatever the fuck and it is dog slow.

Name: Anonymous 2007-04-30 15:58 ID:pLvBtLNK

>>21
Learn to fucking spell. I had to read your post three times to understand what you are trying to say (protip: there's a difference between `it's' and `its'). Anyway, Python indeed sucks really badly for functional programming, and that's a very sad thing. Python itself is pretty useful though, mostly due to the hueg number of do-what-I-want libraries.

Name: Anonymous 2007-04-30 16:14 ID:LLFBVlcK

Python doesn't have lambda's anymore. End of story.

Name: Anonymous 2007-04-30 16:38 ID:Mz6NxB8Y

>>23
ONE WORD, FORCED LACK OF LAMBDAS, THREAD OVER

Name: Anonymous 2007-04-30 16:49 ID:pLvBtLNK

>>23
Python lambdas have always sucked so badly that they have been almost useless. Are they actually going to be dropped in 3K?

Name: Anonymous 2007-04-30 20:49 ID:RmMdNz80

>>21
You can bash Guido for not liking FP much, but Python is the fastest of the modern dynamic languages (at least the barely popular ones).

>>23
Lies

>>25
They're going to be dropped to /opt.
Nah, they'll stay exactly as they are. Guido said so.

Name: Anonymous 2007-05-01 6:07 ID:ZmWZXdsP

>>26
but Python is the fastest of the modern dynamic languages

------------------
$ time python <<EOD
i = 0
while i != 100000000:
    i = i + 1
print i
EOD
100000000

real    0m37.950s
user    0m37.230s
sys     0m0.050s

------------------
$ time perl <<EOD
for (\$i=0; \$i != 100000000; ++\$i ){}
print \$i;
EOD
100000000
real    0m20.060s
user    0m19.890s
sys     0m0.010s
------------------
$ time php <<EOD
<?php
for (\$i=0;\$i !== 100000000; ++\$i);
echo \$i;
?>
EOD
Content-type: text/html; charset=utf-8

100000000
real    0m11.167s
user    0m10.910s
sys     0m0.020s
------------------

Versions:
Python 2.4.3
PHP 5.2.1 (cgi-fcgi)
Perl v5.8.8

uname -a:
Linux Emilie 2.6.20-gentoo-r7 #1 Sun Apr 29 09:52:13 CEST 2007 x86_64 AMD Athlon(tm) 64 Processor 3500+ AuthenticAMD GNU/Linux

Name: Anonymous 2007-05-01 6:09 ID:2+gDRZ+M

Lisp is the fastest of the modern dynamic languages.

Name: Anonymous 2007-05-01 6:37 ID:nXrhTwoy

JScript .NET is the fastest of the modern dynamic languages.

Name: Anonymous 2007-05-01 7:22 ID:Heaven

Use Assembler.

Thread over desu~.

Name: Anonymous 2007-05-01 7:22 ID:+g9m3NvU

Haskell is the fastest of the modern static languages.

Name: Anonymous 2007-05-01 7:29 ID:5HSVbBGx

Machine code is an interpreted language.

Name: Anonymous 2007-05-01 7:34 ID:ZmWZXdsP

>>30
Could assembly (and machine code) be said to be a dynamic language because you can access the data as any type you want it to be?

Name: Anonymous 2007-05-01 8:22 ID:nXrhTwoy

JScript .NET is the fastest of the modern static languages.

Name: Anonymous 2007-05-01 8:24 ID:ehjjvnxF

>>29,34
lol

Name: Anonymous 2007-05-01 8:50 ID:ZmWZXdsP

$ cat >> count.hs << EOD
* count :: Int -> Int
* count i = if i == 100000000 then i else count (i+1)
*
* main = putStrLn (show (count 0))
* EOD
$ ghc --make count.hs -o count
Chasing modules from: count.hs
Compiling Main             ( count.hs, count.o )
Linking ...
$ time ./count
100000000

real    0m10.569s
user    0m10.560s
sys     0m0.010s

$ cat > count.c <<EOD
* main() {
*    int i;
*    for(i=0;i!=100000000;++i);
*    printf("%d", i);
* }
* EOD
$ gcc -o count count.c
$ time ./count
100000000
real    0m0.399s
user    0m0.400s
sys     0m0.000s
$ gcc -O3 -o count count.c
$ time ./count
100000000
real    0m0.003s
user    0m0.000s
sys     0m0.010s

Name: Anonymous 2007-05-01 9:25 ID:2UqWc0AY

>>33
Even though you can treat any sequence of bytes in assembly as whatever type you like, whenever you want without indicating that intent, it's not strictly "dynamic" because there is no automatic type conversion.  There really isn't any types at all.  The only notion of types that assembler has is the difference in some math instructions, which vary depending on data length and whether it's signed or not.  FP instructions are also different than integer instructions.  But your original data can be any type and the assembler nor the program won't bitch, notice, or even care.  Pretty much the only built-in type conversion available period is offered by some sign extend instructions like CBW, CWD, CDQ.  (There are instructions available to help convert binary to ascii or BCD but they need other instructions).  You have to manually do any type conversion yourself.

Name: Anonymous 2007-05-01 9:25 ID:5HSVbBGx

>>33
No. What you described is weak typing. Dynamic typing != weak typing.

Name: Anonymous 2007-05-01 9:29 ID:ZmWZXdsP

>>37
>>38
Ok, thank you both.

Name: Anonymous 2007-05-01 10:45 ID:2+gDRZ+M

>>31
OCaml is the fastest of the modern static languages.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List