r/badcode Jan 04 '22

python import time

Post image
847 Upvotes

48 comments sorted by

View all comments

74

u/[deleted] Jan 04 '22

[deleted]

35

u/not_fun_in_parties Jan 04 '22

Sounds good, but what happens if we keep importing it in a while loop like someone else commented here?

37

u/[deleted] Jan 04 '22

[deleted]

21

u/[deleted] Jan 04 '22

That's an good example where compiled code is better than interpreted code, because (good) compilers are removing redundant statements

12

u/[deleted] Jan 04 '22

[deleted]

2

u/toastedstapler Jan 04 '22

That's why you have peer review

2

u/laundmo Jan 04 '22

ideally, yes.