« first day (1753 days earlier)      last day (3197 days later) » 

10:00 PM
@copy does that mean I'm too complicated? :(
 
good day guys !
had your breakfast ?
 
You're cute, it just won't work between us
 
?
??
???
whos cute ?
 
@copy :( Then I'll have to continue hugging my Doug Crockford Dakimakura :(
 
where is the github chatroom ?
 
10:06 PM
is there a good quick and dirty for promises? need to get up to speed on es6.
 
I think Bluebird has something to do with Promises.
Never used it, though,
 
Quick and Dirty? Yes, that describes native ES6 promises quite well. The only good thing about them is that you can always just use Bluebird and he happy. github.com/petkaantonov/bluebird
 
bluebird looks excellent! I was looking for a quick & dirty tutorial on native promises though...just to know it, really
 
If you know bluebird, you know native promises. All bluebird does is add a couple of extra things, but the syntax is still identical
 
LOL People are giving 100,000$ prize awards for who finds the next largest prime.
Current largest prime found: 2^57,885,161 − 1
opens node
 
10:21 PM
Good luck with that :)
 
You only need to test a few million numbers
Each of which only takes a few megabytes of memory
Should be doable
 
Just kidding though.. I wouldn't actually try to do it
sigh
@copy Is it that hard to generate such big numbers with a very powerful machine? (Lots and lots of ram and cpu power)
 
Regex help needed
^(\d+);([^;]+);[^;]+;[^;]+;[^;]+;(.*)$ my code
 
@iamtery What are you trying to achieve?
 
morning
 
10:27 PM
How can i select the third text, fourth,
 
@catgocat No
 
@copy So what is the big deal
 
The primality test
 
I meant to generate such big primes
 
You take a random number and check for primality
 
10:28 PM
If I remember right, the complexity of testing primes is a big reason why rsa encryption works
 
@copy Sure, and wouldn't a very very powerful computer find some large primes in a couple of days?
 
@NathanJones The hardness of factorization
 
the problem primes is that there isn't a formula to actually find them
 
@catgocat 01;TEST;Delete;Delete;Delete;keep||
 
you have to sort of guess and test, afaik
 
10:29 PM
How do i replace it
 
the larger the number gets, the more tests you have to do
which turns into a lot, the larger the gaps get to the next prime number
 
@catgocat I don't know, probably not
 
Get a computer with 500000 GB or RAM, 1 BILLION GB of hdd, a super powerful CPU
open VC++
 
instead of a trying to use a powerful computer to simply guess with brute force
 
10:32 PM
O(k log^2n)
 
@copy i remember learning big O notation, but I forget what k means
 
I would personally try to find a way to guess about when and where the next prime would occur
eg use process of elimination
 
good plan
 
@Shea there a probabilistic primality tests
which can tell you if a number "might be a prime"
 
10:34 PM
yeah that, use that
 
import Data.Numbers.Primes
import Data.List

main = print . find ((>9^99) . length . show) primes
 
you still have to actually peform a full test on it though, which in case of 2^57,885,161 − 1 is going to take a very very long time
 
quantum computers will get us much further
 
there's gotta be a better way
 
also if your last prime is X and you find prime Z with this method, you can't tell if there isn't a Y prime in bewteen without actually testing all the numbers
@Shea well there might be, there is no proof that there isn't a formula for prime numbers.
 
10:36 PM
you'd find Y before finding Z tho
 
@catgocat not with the probabilistic methods
because these do actually pick a somewhat random range to begin with
 
DNC
Any marketing strategists in here?
 
the idea behind them is to quickly sort out ranges which mostlikely cannot be a prime
 
when you guys become millionaires, take my haskell super program and run it in your quantum super powerful computers
 
10 mins ago, by catgocat
@copy So what is the big deal
that's probably why it's such a big deal
 
10:38 PM
and with 17,425,170 digits for the currently largest known prime it's just going to take a while to check
 
Not with super powerful computers
do I have to say super powerful again??
 
didn't we find the currently largest known prime with super powerful computers? and it took a while
 
not really
i5 3 ghz, 16 gb ram
The discovery was made by Michael Schulz (Michael Schulz) of Germany using an Intel(R) Core(TM) i5-4570 CPU @ 3.20GHz with 16 GB RAM running Darwin 14.3.0. This computer took about 9 hours and 57 minutes to complete the primality test using LLR
 
get your computer as fast as you want, you still wouldn't be able to give me a larger prime than the one you found on demand
 
that's to test the primality of a single number
 
10:40 PM
3
 
I would think you'd somehow have to factor in the power of the computers that failed the test
 
and the next one might be a couple of trillion away
 
The probability of n being prime is about 1/log(n)
 
DNC
some serious math shit is going on in here
 
LargestPrime = LargestPrime + 1 - 1
easy
 
10:49 PM
is the algorithm to find the next prime solvable in polynomial time?
 
@NathanJones it should
 
@NathanJones iirc it's the result of multiplying all the previous primes + 1
Or something similar to that
 
I don't mean the primality test, the "find the nth prime" algorithm
 
@MadaraUchiha nope :P That's just another prime, not the next prime
 
Ah
right
 
10:50 PM
They're now finding primes in the form of 2^x + 1
 
@NathanJones you actually still can
 
wow I'm slow today
 
That was already posted here
 
@Shea that's... depressing
 
now they call me awesome
 
10:56 PM
fun/sad fact: I actually don't have a highschool nick... nobody can say my name or family name right without forcing themselves to...
but they'd still try it for fun
 
my teachers (especially substitutes) use to pronounce my name She-Uh
I encounter more people reading my name tag as a cashier, who pronounce my name correctly
 
so, my family name is Copoț, which should be pronounced as cop + oz, but they almost always read it as cap + ot, or just remove every vowel and say kpz...
it's depressing, but also quite interesting
not that anyone but me cares here :P
 
is it pronounced, "shay"?
 
yeah
 
I didn't know it was a unisex name
 
11:02 PM
afaik, it was actually just a boys name when I was born
then turned unisex
 
so have a cat pic
 
what nationality is Copot?
 
@Shea romanian
 
I thought it was only a girls name
 
I would never guess it had a 'z' sound
I have never met a girl named Shea, only boys
 
11:03 PM
Opposite for me
 
however, I have met girls nicknamed Shea, which is usually short for their full name
 
@Shea well, in most languages in eastern europe the 'z' is written as 'c', so... :P
 
and it's usually spelled Shay
 
Nah, I've only seen it as Shea, and on females. Strange.
 
11:11 PM
It's an Irish surname, odd that we've adopted it as a first name
 
Not really, I'm glad I don't have a common first name
It's not odd at all to want to give your kid a name that isn't common
Infact, I am the one and only Shea Sollars in the entire world.
And if that wasn't enough, I have two middle names
 
"Did you know that 57% of Berries prefer Collin to Callum?"
(ง ͠° ͟ل͜ ͡°)ง You want some, Berries?
 
you want some ass
 
I prefer my jQuery arse-free, thanks anyway.
 
I prefer my ass jquery-free
 
11:22 PM
there's a Backbone joke somewhere in there
 
@NathanJones Yeah, I just don't have the spine to say it *badumtss*
 
11:35 PM
console.log(sum(range(1 , 10) ) ) ; Do we have built-in sum and range?
 
Nope, have a look at generators though, they will help you build one.
!!mdn generator
 
Click on that link - coming from a Python background, I assume?
 
i'd say reduce is a better way to do sum. but generators can make range
 
11:40 PM
we have sum/range in python
range is sequence generator
 
then generator is the JS equivelent
but they are ES6 only, if that matters to you
 
am new to JS, Does latest browsers support ES6?
 
Currently Chrome + Firefox support generators,
Chrome, safari and opera don't.
 
firefox supprts some features, others support less. You need a tool lik babel if you want consistent support everwhere
 
11:43 PM
 
I see the version chrome 44.0.2403.125 on my machine
how do I enable ES6 support on chrome?
 
Some bits are enabled, some aren't.
 
main idea is to avoid writing iterative code like, which has state change
 
You don't really have a choice on which
 
var total = 0 , count = 1;
while ( count <= 10) {
total += count ;
count += 1;

}
c o n s o l e . log ( total ) ;
ok
 
11:48 PM
unless you want long ranges or need iterators, working with plain arrays will be simpler.
 
You can shorten count += 1 to count++, incase you didn't know about the var++, var--, --var, and ++var operators.
 
For such values 2.2222222222222224e+295 we need extra code in C/java. Is there not a limit for values?
 
The limit is +/- 253^-1, I believe.
try Number.MAX_SAFE_INTEGER and Number.MIN_SAFE_INTEGER` in your console
The max safe and min safe are not the limits, but I don't think it is a good idea to go above, dunno though
!!>Number.MAX_SAFE_INTEGER == Number.MAX_SAFE_INTEGER + 1
 
@Callum false
 
Hmm, my Firefox console says otherwise :S
 
11:58 PM
func = window['Number']
func.MAX_SAFE_INTEGER
9007199254740991   // Is this the limit for integer
 
playing with iterators myself, so I implemented sum(range()): es6fiddle.net/icy0bzgm
 

« first day (1753 days earlier)      last day (3197 days later) »