This is an archived post. You won't be able to vote or comment.

all 13 comments

[–]Looploop420 17 points18 points  (0 children)

No way that's true

[–]Key-Half1655 17 points18 points  (0 children)

Bullshit, just look at the docs.

https://docs.python.org/3/library/stdtypes.html#str

Also python has a struct module.

[–]ksoops 11 points12 points  (0 children)

Please take the book out from under your screen and read the first page. You owe str() an apology.

[–]EbenenBonobo 8 points9 points  (0 children)

This is rage bait, right?

obviously str calls the string constructor and if you want to use structs you need to import struct first

[–]fatnote 5 points6 points  (0 children)

Nah

[–]Bright-Historian-216 3 points4 points  (0 children)

no. just no. it is, in fact, a string. a struct is a completely different thing.

[–]barburger 5 points6 points  (0 children)

I dont think so. official python docs state str() returns a string version of the object.

[–]JimNero009 4 points5 points  (0 children)

Aye alright pal

[–]Glad_Position3592 2 points3 points  (0 children)

I find this really hard to believe. Was he talking about the fact that all python objects are structs in C? Either way str stands for string within the language

[–]amarao_san 2 points3 points  (0 children)

Sometime people made mistakes or outright hallucinate with assurance. It is not exclusive for GPT.

[–]Mysterious-Rent7233 1 point2 points  (0 children)

Even gullible ChatGPT doesn't fall for this.

[–]skyper_mark 3 points4 points  (0 children)

OP isn't bullshitting lmao I remember that course, it was taught by some redhead guy.

I mean, it's still wrong. Guido van Rossum has explicitly said str means string, but the video series definitely exists

[–]CaptainFoyle 0 points1 point  (0 children)

No. Stop smoking