Share your repls and programming experiences

← Back to all posts
I made a code that guesses your age!
AH3973 (37)

You might know the trick to figure out someone's age already. This code is not just a lot of bologna because your final number will contain the number you initially chose.

Commentshotnewtop
awesome10 (184)

@DynamicSquid

ITS A CONSPIRACY!!!! EVERYONE IS IMMORTAL!!!! ITS ALL LIESSSSSSSSSSSSsssSSSSssssSSSSssssSSSSSSSssss

ok maybe i overdid that
WarriorDefender (3)

@awesome10 I was laughing my ass off LOL

WarriorDefender (3)

@DynamicSquid r u on discord? send me a frnd request to TheOriginalDude#0585

johnstev111 (218)

@DynamicSquid Apparently I haven't even been born yet:

Pretty much what I'd expect, being a firefish.

maxyang (27)

So you are 4029 years old. I think you mean BC not AD...

voxico (1)

@maxyang BC and AD are the same <:-|

SixBeeps (2295)

@voxico i can't tell if you're joking or not

voxico (1)

@SixBeeps no lol I was joking

johnstev111 (218)

@voxico BC = Before Christ AD = Anno Domini

voxico (1)

@johnstev111 Annon Domini = Year of the Christ

sudevr (2)

Did you just make some bologna until the 'enter your year of birth' and 'did your birthday pass this year' questions

AH3973 (37)

@sudevr no, this trick is supposed to performed at like a magic show or something. it is hard to do when it isn't live.

AH3973 (37)

The good thing about people chatting on my post is that now it is trending.

FrasherLGray (2)

If I give it my birth date, of course it would know my age, clever formula or no.

AH3973 (37)

@FrasherLGray this trick works better when like a magician is doing it live,

DynamicSquid (1878)

@AH3973 oh yeah, i've seen those before

ShivankChhaya (65)

This is awesome! It guessed my age correctly!

ShivankChhaya (65)

@ZDev1 Seriously what do you mean?

ZDev1 (173)

@ShivankChhaya yay!
How many trophies you have?

ZDev1 (173)

@ShivankChhaya oh too low
i am 10,563!
( ͡° ͜ʖ ͡°)

ShivankChhaya (65)

@ZDev1 nice! I started a couple months ago but I dont play that much.

ZDev1 (173)

@ShivankChhaya oh really?
I had one year ago!

ShivankChhaya (65)

@ZDev1 Wanna make a mutiplayer repl thats like brawl stars, but text based?

ShivankChhaya (65)

@kbadrinath_tcsp so you mean you'll make it also? i dont get it.

kbadrinath_tcsp (190)

I mean i'll help also its me keshav @ShivankChhaya

ZDev1 (173)

@ShivankChhaya ok! why not
By the way, I have all the legenedries!

Nettakrim (348)

@DJWang
are you on windows or mac?

DJWang (1129)

@Nettakrim I'm on mac. I honestly don't know why they could ask such a hard question. 4*2 is impossible!

Nettakrim (348)

@DJWang to answer this question we need to look at the history of mathematics

maths was invented in 2017 with the song "Mans not hot" by Big Shaq wherein he says "2 plus 2 is 4 minus 1 thats 3 quick maths"

this set the groundwork for the Axiom of Infinity which states if there is a set I (the set which is postulated to be infinite), such that the empty set is in I, and such that whenever any x is a member of I, the set formed by taking the union of x with its singleton {x} is also a member of I.

as you can see in the song, 2+2=4 so 4*2 can essentially be seen as (2+2)*2, in (2+2)*2 there are 3 twos and as further established in the song, 3 can be written as (4-1)
of course 4 is 2+2 so really (4-1) should be written as (2+2-1)

so this means that (2+2)*2 should really be written as
((2/3*3)+(2/3*3))*2
((2/(4-1)*(4-1))+(2/(4-1)*(4-1)))*2
((2/(2+2-1))*(2+2-1)+(2/(2+2-1))*(2+2-1))*2 which is much easier to understand

solving ((2/(2+2-1))*(2+2-1)+(2/(2+2-1))*(2+2-1))*2 is rather simple
((2/(2+2-1))*(2+2-1)+(2/(2+2-1))*(2+2-1))*2

first we will solve ((2/(2+2-1))

2-1 is 1, so we can take 1 + from 2+2 to get 2+1 which is 21
2+2 is 4 so (2+2-1)) is 4-1
the opposite of (2+2-1)) is ((2/
4-1 is the opposite of 1+4
1+4 is 14
so ((2/(2+2-1)) is 14/21
14/21 is 0.666...
this means we have:
0.666...*(2+2-1)+(2/(2+2-1))*(2+2-1))*2

then we will solve (2+2-1))*2
2+2+1 is 5 and 2+2 is 4
the average of 5 and 4 is 4.5
4.5*2 is 9
so now we have
0.666...*(2+2-1)+(2/(2+2-1))*9

finally we will solve (2+2-1)+(2/(2+2-1))
2+2-1 is 3
in (2/(2+2-1) we can ignore the -1 for the time being to get 2+2
2+2 is 4, we can then take the / from 2/ to get 4/3
4/3 is 1.333...

finally this means the simplified form is
0.666...*1.333...*9
calculating 0.666...*1.333... is incredibly easy
0.666...+0.333 is 0.999...
0.999...-1 is 0.888...
so we have
0.888...*9
0.8*9 is 7.2
0.08*9 is 0.72
0.008*9 is 0.072
this continues infinitely in accordance with the previously stated axiom of infinity
the first number is 7 and the rest for infinity are (7+2) or 9
this means the full number is 7.999...
7.999... is the same as 8

so therefore the answer is:

8

DJWang (1129)

@Nettakrim Wait what was the question

DJWang (1129)

@Nettakrim Wow I am not good at math. Thanks for the totally simple and easy-to-understand explanation of the whole universe. Really appreciate it.

TheDrone7 (987)

but it is correct....

LOLLIPOP06 (24)

so you are -98487?

BlaineyBoy (0)

it guessed 11 and i am 10 but that is still really cool

dillonjoshua68 (28)

I’m younger than you @DynamicSquid, we’ll younger in negative years?

WaruchJiratanak (2)

It got my age correct.

mathiasaboye (33)


Wait how did it know!?!??!?!?!?!?!?!?!?!?!?!?!?!?? (⊙o⊙)

Name12 (43)

hello, this is a very nice code!! but I made some improvements on this. her's the link to the program:
https://repl.it/join/ojaetikz-name12
be sure to check it. and also, I posted it on talk, please do not mind. because I said that it is produced by you, only the artwork is mine. (^_^)

Warhawk947 (511)

@Name12 please, no advertising.

Funkus (36)

nice, I'm 193453428475 years old ;)

CodeLongAndPros (868)
Enter your year of birth (If you were born in AD (Which I Highly Doubt You Were) Use Negative Numbers): -2007 
Your current number is now: 4727
The hundreds digit in your number is the number is the number you initially chose.
Remove that digit from your current number and that is your age.
So you are 4027 years old.
This is the formula to figure out somebody's age: (Chosen Number * 2 + 5) * 50 + Yes: 1770/No: 1769 - Year Of Birth - (100 * Chosen Number)
RaphTheGreat (0)

This literally is too hard

SixBeeps (2295)

How'd you guess my age correctly?!

Kopamed (221)

But what is the point if you are just gonna ask my date of birth. This just sounds like asking someone for their age with extra steps. lol

AH3973 (37)

@Kopamed this magic trick is supposed to be performed live so that's why you may think I tried to throw you off with a bunch of math. actually read

Kopamed (221)

@AH3973 Dude chill. no need to be rude.

awesome10 (184)

right...
i recommend you make it so you can't do that...

dillonjoshua68 (28)

But the program is still good, it’s accurate if the correct age is entered @AH3973

andliu766 (4)

From Me to Math Ma: (Privately) (3:30 PM)

Hello?
There is no sound

From Me to Math Ma: (Privately) (3:58 PM)

0

From Me to Math Ma: (Privately) (4:30 PM)

5

From Me to Math Ma: (Privately) (5:05 PM)

4
-72

From Me to Math Ma: (Privately) (5:13 PM)

10


This is what i got

adl212 (15)

@AH3973, you have a typo where it asks What is you current number plus 1769?
Instead, it should say What is your current number plus 1769?

[deleted]

yay! it is correct. i didn't use negative and it correct! It says i am 10 years old and i am!