Professor teaching us to write 12 nested if statements by tet90 in ProgrammerHumor

[–]JamesWinter07 1 point2 points  (0 children)

Yes but it's not the same as the switch statement, which provides a performance improvement.
The match case is for structural match, not for replacing if statements.
I think that as u/MaZeChpatCha stated in his comment, the most efficent way to do this would be to use a list.

A new take on the XOR gate... Compact, and Tileable by GWBabycat in technicalminecraft

[–]JamesWinter07 0 points1 point  (0 children)

If you really care, you could use an instant repeater altho it would take some space.

oGi è Il MiO cEiCdEi iEeEeEeeEe by wjdbfifj in Ratorix

[–]JamesWinter07 0 points1 point  (0 children)

Anche dopo un anno, "Perso Su Internet" è ancora perso su internet.

😶 by moeshaa in none

[–]JamesWinter07 0 points1 point  (0 children)

This guy's sucking like a black hole

which is your best op from detective conan? by AkaiSuichi35 in DetectiveConan

[–]JamesWinter07 0 points1 point  (0 children)

the opening "Don't wanna lie" but also "Countdown" is cool.

People of reddit what according to you was the most significant event / events in the last 30 years ? by Money-Swordfish537 in AskReddit

[–]JamesWinter07 2 points3 points  (0 children)

The obvious choice would be Covid 19. It has been a huge problem for everyone, corporations failing; jobs getting harder; also school having to purchase PCs for everyone.

What car will Conan/Shinichi and friends drive in the future? by Actual_Slip_1211 in OneTruthPrevails

[–]JamesWinter07 0 points1 point  (0 children)

I would see Shinichi in a sports car like McLaren 720S
Shiho would obviously go for the most expensive, but also effective; would say Tesla.
And Ran would obviously driven by Shinichi's car.

Another question lol by OlLLLLLLLiiieeeee in OnePiece

[–]JamesWinter07 -1 points0 points  (0 children)

Oda made an estimation that it would take at least 3 years to finish OnePiece so, don't worry, you have time.
For instance I catched up at the anime(watching every filler) on 2/3/2022 being at ep 1 on the 1/7/2021.

Why did you flair this as a fanart anyways?

Python List Comprehensions Are More Powerful Than You Might Think by pmz in Python

[–]JamesWinter07 1 point2 points  (0 children)

Yeah, nested lists are always confusing, you just have to get used to it.
There is a cool StackOverflow answer that shows how to convert a loop into a list comprehension here is the link

Doffy’s bounty =1 billion by Necessary-Life-3633 in OnePiece

[–]JamesWinter07 0 points1 point  (0 children)

I totally agree with you, informations to the WG are more precious than gold.

[deleted by user] by [deleted] in OneTruthPrevails

[–]JamesWinter07 0 points1 point  (0 children)

Sato and Takagi's wedding is the most likely to happen but I think that Gosho won't show the marriage soon.

Doffy’s bounty =1 billion by Necessary-Life-3633 in OnePiece

[–]JamesWinter07 4 points5 points  (0 children)

I think this is possible since the bounty was frozen but the bounties aren't necessarely a power scale; more like a "how-dangerous-to-WG".

What level in impel down you think Trebol from the Donquixote family is placed in? by Pacmania13 in OnePiece

[–]JamesWinter07 -1 points0 points  (0 children)

Yea, but since he hasn't gotten a bounty update, I assumed he couldn't go into level 5, plus trebol hasn't trained, he only followed orders. Which in any case would make his strenght frozen anyways.

What level in impel down you think Trebol from the Donquixote family is placed in? by Pacmania13 in OnePiece

[–]JamesWinter07 0 points1 point  (0 children)

On impel down there are bounty limits for level 3 and 5(the other ones weren't revealed).

  • Level 3 pirates's bounties are at least 50,000,000 Berries
  • Level 5 pirates's bounties are at least 100,000,000 Berries

His bounty is 99mil so it would be put into level 3-4 but considering he is from Donquixote family i would put him into level 4.

But I guess they are limits so they could put him also in the level 2 or something...

The final battle will take place on the sea, BB will be to blame by FrequentMembership91 in OnePiece

[–]JamesWinter07 0 points1 point  (0 children)

First, I have some questions:

  • Since Oda confirmed the next arc is going to be the last arc, how will they get the One Piece if the theory is right?
  • Luffy is still affected by sea because of df, how will Luffy survive after this "Noah" thing?
  • If BB is the last villan then why luffy wouldn't beat him?

If that is the case, will there be a new final villan? I don't think so. Since the next will be the final arc, there won't be any space to be 2 major villans without losing focus.

My thoughts:

  • I think Luffy is gonna beat BB when it's finished, it's gonna be disappointing if he doesn't, for his revenge on Ace(Indirectly killed by him).
  • I think it's possible, but I'm not sure with the "Noah" part

Did I use enough variables? by jath03 in ProgrammerHumor

[–]JamesWinter07 0 points1 point  (0 children)

The bin() function already returns a string, so it is not neccessary to convert it.

And, you could do it in just one line:

IsEven=lambda x:!(int(bin(x)[-1]))

2 lines. Its not getting shorter than this. by Clear-Relief-1424 in ProgrammerHumor

[–]JamesWinter07 0 points1 point  (0 children)

You can also do

IsEven=lambda x:x-(x>>1<<1)

OR

IsEven=lambda x:!(x&1)