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

Pages: 1-4041-

python

Name: Anonymous 2007-01-25 10:08

To my surprise, I was just struck by the power of Python

Name: Anonymous 2007-01-25 10:14

>>1
It's nice, isn't it?

Name: Anonymous 2007-01-25 10:59 (sage)

not as powerful as perl

Name: Anonymous 2007-01-25 11:41

>>1
MOM???

Name: Anonymous 2007-01-25 11:56

>>4
Billy!?  What the fuck are you doing at this site!  It is 18+!!  You stupid son of a bitch... oh wait..., I'll send you a fucking virus or something.

Name: Anonymous 2007-01-25 12:57

>>3
Lies. What does Perl do that Python doesn't in an equally as powerful way? Does Perl have list comprehensions, generators, ...?

Name: Anonymous 2007-01-25 14:09

>>6
"What does Perl do that Python doesn't in an equally as powerful way?"

Confuse the ever-loving shit out of someone trying to follow it.

Name: Anonymous 2007-01-25 14:13

python = SHIT
discusson over.

Name: Anonymous 2007-01-25 14:27

>>8
Cmon. You can do better than that.
Make a case against it.

Name: Anonymous 2007-01-25 14:59

Perl has two gems: regular expressions and CPAN.

It's too bad it has so many damn nooks and crannies. Next to C++ it's the most complicated language ever.

Name: Anonymous 2007-01-25 15:34

here is some Python copy-paste:
if s == "slkdflsf":
if t == "lskdf":
elif x == 12:
if z == 12:
pass

Woops, fucked up the copy-paste, fucked up the algorithm at the same time, worst language ever :D

Name: Anonymous 2007-01-26 3:50

BY THE POWER OF GREYSKULL

Name: Anonymous 2007-01-26 4:01

>>11
seconded

Name: Anonymous 2007-01-26 4:01

Python is shit BECAUSE http://compsoc.dur.ac.uk/whitespace/

Name: Anonymous 2007-01-26 4:50

>>14
I consider forced use of whitespace to be one of the good features of Python.

Then again, if you just meant that the language Whitespace is better than Pytghon, IHBT.

Name: Anonymous 2007-01-26 4:58

>>10
Okay, Python's regular expressions lack the experimental features but they have everything else. There's no syntax for them, but you can write simple wrappers that will make their use very simple. I've written and published mine before, if you're interested I can repost the URL.

Python's standard library > CPAN for most cases, and for the rest there's Google.

>>11
That's a good feature. It prevents fucktards from writing unindented code, and prevents shit HTML copypastas from being used to copypasta shit unindented code. Have you actually used Python? At first, forced indentation looked weird to me (to say the least), but after using it for, like, 2 days, I realized it was the best idea ever. Not only you save lines and fit more useful lines on screen by sparing the }, but you know others are forced to write more proper code, which helps. I already indented code this way, so for me, it doesn't do anything (plus it saves me from using }); the real advantage is that others don't write shit.

Name: Anonymous 2007-01-26 4:58

>>1-2
Suteki da ne?

Name: Anonymous 2007-01-26 5:56

"elif"? wow, python really is shitty...

Name: Anonymous 2007-01-26 7:12

i agree with anonymous. 100%.

Name: Anonymous 2007-01-26 7:33

>>16
um YES I have used python, how the fuck else could I comment on why it is BAD.

no this is not a good features "fucktards" as you call them, will write bad code no. matter. what.

Not only you save lines and fit more useful lines on screen by sparing the }
who is stoppping you doing

if(x) {
   printf("asdf\n");
   return 5; }

For example...

>>18
agreed

Name: Anonymous 2007-01-26 7:51

um YES I have used python, how the fuck else could I comment on why it is BAD.
Umm, cause you're a troll? Not saying you are, just giving an example to why the question was relevant.

And I realize forced indentation is not for everybody, sorry, can't really do much about that. Just pick some other language.

Also, I'm not >>16

Also, cocks

Name: Anonymous 2007-01-26 8:12

>>21
Basically any language that FORCES you into any particular code style, or even programming paradaigm is FUCKED UP and DO NOT WANT

Name: Anonymous 2007-01-26 8:15

sum tymes my python gets me in too much trouble, but usually not enough.

Name: Anonymous 2007-01-26 8:36

>>22
Does C forcing me to use curly brackets count?

Name: Anonymous 2007-01-26 8:37

>>24
Not to mention the fucking semicolons. I definitely DO NOT WANT them...

Name: Anonymous 2007-01-26 11:37

>>18
elif is like Python's switch/case, only you can test for a completely different condition in it. Nothing bad with that.

>>20
um YES I have used python, how the fuck else could I comment on why it is BAD.
Most people who say forced intentation is bad are just people who had a quick look at Python, saw it, and thought "OMG RESTRICTIVE, OMG COBOL" without really giving it a try to discover it's easy to get used to and desirable afterwards. In fact, right now I'm fixing some PHP code and I'm wishing PHP had forced indentation because some lines are wrong and I don't like the braces convention used by this guy.

>>18
who is stoppping you doing
Not-forced-indentation is stopping me, because if I do that, there's no easy way to see the closing brace, and I can't be sure indentation is correct, unlike Python. That would work in a language with forced indentation, then again, when you have forced indentation you don't need braces.

>>22
Python doesn't force any programming paradigm into you, unlike pretty much anything else. It doesn't force shitUglyCase either. It doesn't force you to use tabs or spaces, and how many of them, not even to use the same amount of them, and never within parenthesized expressions or multiline quotes. It doesn't force you to not write shitty obfuscated code. The only thing it forces is to have some decency when writing blocks, so that you keep your code readable. That can't be bad.

Also, >>24 pwned >>22

>>25
Ah, semicolons. I don't mind them myself, but they are quite superfluous... I find JavaScript's a good solution for C-style languages with braces and shit: semicolons optional, you can use them when you need them, or everywhere. And in a language like Python, with indentation, you don't need them at all.

Name: Anonymous 2007-01-26 12:10

i like python, i got tired of it and tried using ruby, then i realised i liked python better than ruby

Name: Anonymous 2007-01-26 12:36

no C does not force you to use {}
for example

if(x)
  y();

Name: Anonymous 2007-01-26 13:18

>>28
only if there's just one instruction, fucktard

Name: Anonymous 2007-01-26 13:56

>>29
put on your glasses NERD, and look at the example I gave again.

Name: Anonymous 2007-01-26 14:39 (sage)

elif is like Python's switch/case, only you can test for a completely different condition in it. Nothing bad with that.
and it's so much easier to read than "else if".

Ah, semicolons. I don't mind them myself, but they are quite superfluous... I find JavaScript's a good solution for C-style languages with braces and shit: semicolons optional, you can use them when you need them, or everywhere. And in a language like Python, with indentation, you don't need them at all.

and then there's perl, where you can do crazy stuff like this:
print "internet\n",
print "lol "

>>28
even better:
x?y():z();

Name: Anonymous 2007-01-26 17:41

You people whine too goddamned much.

All languages suck. All of them. Every single last goddamned one of them.

Except for assembly. Now, there's a man's language!

Name: Anonymous 2007-01-26 18:40

>>28
Stupid. Only for one line, unless you love wasting your time creating functions, and since C functions aren't closures, waste extra time, confuse maintainers and risk bugs by using lots of nice parameters.

Name: Anonymous 2007-01-26 19:07

Python's standard library > CPAN for most cases, and for the rest there's Google.
I have to disagree here. Python has a lot going for it, but CPAN is Perl's crown jewel. I've used both Python and Perl in a pro capacity in mid-sized apps, and Python's standard library really doesn't come anywhere close to CPAN...

...although you have to like something that's well tested.

Name: Anonymous 2007-01-27 4:21

>>32
LOL ASSEMBLY IS FOR OLD PEOPLE!

Name: Anonymous 2007-01-27 4:53

>>15
forced use is bad, not good, moron. programming is here to help, not to force intelligent people because noobs have a problem and can't indent their code

Name: Anonymous 2007-01-28 3:48

python is fun, but ruby is funner. I just wish python had more metaprogramming stuff, all it has is eval() and friends.

Name: Anonymous 2007-01-28 3:59

>>35
I AM old people, pup. ;)

I honestly haven't touched assembly, other than for PalmOS in maybe 12 years.

Name: Anonymous 2007-01-28 4:10

>>38
you haven't debugged a lot in those 12 years, I pity you

Name: Anonymous 2007-01-28 10:35

youtube was written entirely in python. good 'nuff for me

Name: Anonymous 2007-01-28 18:47

>>39
If you are doing all your debugging at the assembly level, you are doing it wrong.

Name: Anonymous 2007-01-29 12:21

>>36
Truth, in an ideal world. Problem is, you don't live alone in the world, and it is full of morons, so by mere statistics, more often than not, you'll be reading idiots' code, not smart people's code. (Plus, idiots' code needs more fixing and maintenance.)

Name: Anonymous 2007-01-29 12:42

>>42
That's why we have Haskell, where only smart people are able to write code.

Name: Anonymous 2007-01-29 15:31

>>43
Please post a working example of how to generate random numbers in Haskell. It's hilarious.

(When we did it we were forced to pass around that fucking random seed to each and every function)

Name: Anonymous 2007-01-30 7:09

>>44

rollDice :: IO Int
rollDice = getStdRandom (randomR (1,6))

Name: Anonymous 2007-01-30 8:20

>>45
JAJAJAJAJAJAJAJAJA I LOLED THATS HILARIOUS!!1

Name: Anonymous 2007-01-30 8:22

>>45
How comes you can do it without using a RandomGen g?

Name: Anonymous 2007-01-30 8:37

>>47

I use the global random number generator

Name: Anonymous 2007-01-30 14:22

>>48
OIC
Would you also mind showing how to open a file, write a line of text to it, and then close it?

For good measure I'll do it in Python:
file = open("file", "w")
file.write("text")
file.close()

Name: Anonymous 2007-01-30 15:09

When we did it we were forced to pass around that fucking random seed to each and every function

Someone doesn't know about monads!

Name: Anonymous 2007-01-30 15:42

>>50
Exactly! Now would you please give the open/write/close file example, because I happen to believe it involves monads too!

Name: Anonymous 2007-01-30 18:05

>>49
You could have simply done:

open('file', 'w').write('text')

Name: Anonymous 2007-01-30 18:15


import System.IO

main = writeFile "file" "text"

Name: Anonymous 2010-12-17 1:30

Are you GAY?
Are you a NIGGER?
Are you a GAY NIGGER?

If you answered "Yes" to all of the above questions, then GNAA (GAY NIGGER ASSOCIATION OF AMERICA) might be exactly what you've been looking for!

Name: Anonymous 2010-12-17 1:40

This post brought to you by the Gay Nigger Association of America

Name: Sgt.Kabu貝沑kiman扆厭 2012-05-28 22:05

Bringing /prog/ back to its people
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy

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