- 0 Posts
- 47 Comments
In the U.S., you can build rockets all day long, they cannot be guided.
https://www.law.cornell.edu/uscode/text/18/2332g
You’d have to convince the feds it was never designed to be a weapon. Good luck with that.
💀
nxdefiant@startrek.websiteto Python@programming.dev•Statically Typed Functional Programming with Python 3.1222·11 months agoYeah, never said it was, just that if you really want to emulate that style you mostly can.
nxdefiant@startrek.websiteto Python@programming.dev•Statically Typed Functional Programming with Python 3.121·11 months agox = foo(y:=bar(), baz(), y) or z
should work assuming foo bar and baz are functions being called?if this is setting y to the effect of bar() + running baz after, then:
x = [bar(), baz()][0] or z
might work
and if you need y to be defined for later use:
x = [(y:=bar()), baz()][0] or z
but thats from memory, not sure if that will even run as written.
if I get to a real computer I'll try that with an actual if statement instead of a bastardized ternary.
nxdefiant@startrek.websiteto Python@programming.dev•Statically Typed Functional Programming with Python 3.1221·11 months ago“a = x if foo else y” is a perfectly cromulent statement!
iPython makes experimenting in an interactive manner so easy, I use it every day.
Up until now most people hated when shit randomly popped up while they were typing.
The Apple went and made the iPhone and now we have a whole generation that expects it.
Have you considered writing your own projects that you have to hide from your employers, and be careful with whom you discuss, so as to avoid the legal complications of the company owning your work?
nxdefiant@startrek.websiteto Programmer Humor@programming.dev•STOP DOING DEPENDENCY INJECTION33·1 year agoI’m gonna need a bell curve hooded figure meme template of this comment, this is comedy gold.
nxdefiant@startrek.websiteto Programmer Humor@programming.dev•It's time to mentally prepare yourselves for this121·1 year agoTime is an illusion, lunch time doubly so.
nxdefiant@startrek.websiteto Programmer Humor@programming.dev•Computer components cheat sheet2·1 year agoabsolutely.
nxdefiant@startrek.websiteto Programmer Humor@programming.dev•Computer components cheat sheet81·1 year agoI would say it’s pretty accurate across the grid, but I’d swap HDD and ram. HDD is chaotic neutral, because it can turn into a maraca at any moment.
nxdefiant@startrek.websiteto Programmer Humor@programming.dev•Dad has the chops to be a project manager.11·1 year agoI am humbled by your chess of many D’s.
nxdefiant@startrek.websiteto Programmer Humor@programming.dev•Dad has the chops to be a project manager.15·1 year agoYou don’t even need to support anything older than the last windows hot fix with requirements like that.
like, even bash, cat, ls, etc?
nxdefiant@startrek.websiteto Python@programming.dev•how to send the icecream output to a log file? [solved]1·1 year agoIf you’re talking about the package icecream, there’s “ic.format()” that returns a string you can log, instead of printing directly to standard out.
More generically, you can have pythons logger capture all of standard out, but that’s kind of a shotgun approach, and depending on what your doing, may have some side effects you don’t want.
There’s an earlier bit that complements that nicely: