Jump in the discussion.

No email address required.

If you divide by zero and it returns true, then it's an odd number.

teeeheee boomer joke


Krayon sexually assaulted his sister. https://i.rdrama.net/images/17118241526738973.webp https://i.rdrama.net/images/17118241426254768.webp https://i.rdrama.net/images/17156480765435808.webp

Jump in the discussion.

No email address required.

:#marseyconfused: what?

Jump in the discussion.

No email address required.

Yes and no. Depends on the datatype and language. But divide something by 0 doesn't result with a value 0 i think it is infinity

In progaying 0 is false and almost everything else is true. I can put the letter A and boolean check and get true.

Jump in the discussion.

No email address required.

so how would dividing an even number by 0 make false then

Jump in the discussion.

No email address required.

Yeah idk what he means either. Dividing by 0 =infinity

:#marseygigaretard:

Jump in the discussion.

No email address required.

Divided by zero is simply normally undefined. But you can program to have defined behaviour.

Also it makes sense if you think about it.

1/0.1 = 10

1/0.01 = 100

1/0.001 = 1000

So the closer you get to 0 the bigger the number. So instead of using real number to define it just a use ∞(infy)

Jump in the discussion.

No email address required.

I have traps disabled (they are gay) so the result is undefined :marseythumbsup:

Jump in the discussion.

No email address required.

So the closer you get to 0 the bigger the number.

Aka infinity

Jump in the discussion.

No email address required.

Yeaah....I wouldn't say that exactly. It's just a programmed behaviour and mathematicians hasn't proved it is infinity if division by 0

Jump in the discussion.

No email address required.

1/(-0.1) = -10

1/(-0.01) = -100

1/(-0.001) = -1000

Jump in the discussion.

No email address required.

zoz

Jump in the discussion.

No email address required.

zle

Jump in the discussion.

No email address required.

More comments

Dividing by 0 =infinity

No it isn't, at least when considering the real numbers. It's undefined. That is different from infinity. And the short example below where the denominator is successively decreased is not sufficient to show that division by 0 is infinity. You can also approach zero from the negatives in which case the value gets progressively smaller (i.e. tend towards negative infinity). This is a case where the right hand and left hand limits of lim_(x->0) 1/x differ and hence the limit does not exist and division by zero is undefined.

Jump in the discussion.

No email address required.

Look dude im not gonna argue about this with you. I know number, ok. Off hand, i can list out dozens of em. Hundreds maybe. Thats off hand (no google or books). All real numbers too, not whatever made up ones you come up with.

So please, leave the numbering to the experts (me)

Jump in the discussion.

No email address required.

:#marseyautismcap:

Jump in the discussion.

No email address required.

Lame boomer joke lol But I like lame dad and boomer jokes. Dad and boomer jokes are probably the same though. lol


Krayon sexually assaulted his sister. https://i.rdrama.net/images/17118241526738973.webp https://i.rdrama.net/images/17118241426254768.webp https://i.rdrama.net/images/17156480765435808.webp

Jump in the discussion.

No email address required.

Neighbor what are you smoking today

Jump in the discussion.

No email address required.

Idk shit about coding but do you really need 12 files to do something like this?

:marseyconfused:

Jump in the discussion.

No email address required.

node.js devs will borrow everyone else's code and pretend they know how to code

Jump in the discussion.

No email address required.

No but JS devs are braindead r-slurs

:#marseygigaretard:

Jump in the discussion.

No email address required.

Well paid braindead r-slurs thank you very much

Jump in the discussion.

No email address required.

JS devs should be executed and JS should be thrown in the fire with their bodies

Jump in the discussion.

No email address required.

You don't, but if someone else puts up a repo that does it in 12 files then it's quicker and easier to use that than write your own code

Jump in the discussion.

No email address required.

Is it really faster than writing n % 2 === 1?

Jump in the discussion.

No email address required.

No but it's easier because you don't actually need to know how code works

Jump in the discussion.

No email address required.

yes. I've tested it in production.

Jump in the discussion.

No email address required.

excuse me sir, you missed some edge cases which is why is-odd exists.

const isNumber = require('is-number');

module.exports = function isOdd(value) {

 const n = Math.abs(value);

 if (!isNumber(n)) {

   throw new TypeError('expected a number');

 }

 if (!Number.isInteger(n)) {

   throw new Error('expected an integer');

 }

 if (!Number.isSafeInteger(n)) {

   throw new Error('value exceeds maximum safe integer');

 }

 return (n % 2) === 1;

};

Jump in the discussion.

No email address required.

Stupid, maybe you should know what type n is.

Jump in the discussion.

No email address required.

Welcome to JavaScript

Jump in the discussion.

No email address required.

lol that javascript has shit like this in the first place

Jump in the discussion.

No email address required.

Here's an overtly complex rendering in Python 3.7

def isodd(n):
return n % 2
Jump in the discussion.

No email address required.

Anyone using this library supports Trump.

Jump in the discussion.

No email address required.

Nice post, bro! I posted it to twitter.

The best #git #repo ever lmao USED BY 880K #C https://rdrama.net/h/slackernews/post/157917/the-best-git-repo-ever-lmbo #code #gud #ur

Jump in the discussion.

No email address required.

Okay big boy I'm out here getting paper while you're posting in a cat worshipping :marseytrain: cult

Snapshots:

Jump in the discussion.

No email address required.

Why are there so many commits for such a simple thing?

Jump in the discussion.

No email address required.

880k r-slurs living among us

Jump in the discussion.

No email address required.

What's a %?

Jump in the discussion.

No email address required.

mowoduwus uwupoowata fwinds out if a nooombaw is dubisible by anutta nooombaw by weturnin the wemainda.

Jump in the discussion.

No email address required.

It is a mystery 👻

Jump in the discussion.

No email address required.

:itisamystery#:

Jump in the discussion.

No email address required.

Link copied to clipboard
Action successful!
Error, please refresh the page and try again.