« first day (1635 days earlier)      last day (3306 days later) » 

user3949359
9:00 PM
@Loktar What resolution would you find acceptable
 
@taco what was his rank?
 
@Shmiddty with 25 years experience
 
at least 1440p
 
@NickDugger E-6
 
there is a tester online, let me see if I can find it
 
9:00 PM
@rlemon something like that. haha
 
Why doesn't this work? var swapValues = [].reverse.call;
 
@taco My father retired as a Colonel
 
@Loktar 4k rift
 
but [].reverse.call(arr) works.
 
user3949359
@Loktar What about the rest of the helmets?
 
9:00 PM
!!afk FOR REAL!
 
@Catgocat the first is a function reference
 
@nosille no, `90s displays like
 
and?
 
You're not invoking the function, you're assigning swapValues to the function
 
9:01 PM
@NickDugger my dad was enlisted, and couldn't get past that rank. He's really introverted, though, so maybe that's why
 
thats actually a really good simulator of how the rifts (the dk1 and 2 anyway) look
 
@taco My father is just a badass
lol
 
click on low persistance for the dk2, and 1080
 
@SterlingArcher I don't quite get it.
 
@Catgocat I'll show you an example
 
9:02 PM
I get my work ethic from my father; work your ass off until you retire.
 
@SomeKittens dude, gulp is obsolete, it's all back to make now
 
one my girlfriend's dad was a colonel of a navy base in pensacola.... glad he never found out the things we did in his house.....
 
function derp() { return "herp"; } you have your function
 
damn, you went there with the herp.
 
@Loktar why does it make everything blurry?
 
9:03 PM
@Loktar what's the country code for spain?
 
var x = derp; //x is now a callable reference to derp(), aka, you call it by x();
 
@FlorianMargaine again?!?
 
@ssube the dk1 doesn't have low persistance so moving around is blurry
@FlorianMargaine umm I don't know.. is it SP?
 
@Loktar why does it persist anything?
@FlorianMargaine es?
 
@Sterling Yup, why wouldn't that work with .call ?
 
9:03 PM
@Loktar no, es
herp-es
 
ha
 
user1596138
Hey this recruiter actually read my resume! I'm 1 for 7
 
I only need to know 3 letters, USA
 
@Catgocat because call is a function, and you're not invoking it
 
fucking chauvinist
 
9:04 PM
So it's not returning anything
 
But if your x = derp is a callable reference to the function derp, wouldn't x = ..cal be a callable reference to the function call ?
 
@Loktar ^
 
@ssube I honestly can't remember the low persistence stuff, like what it means, i want to say it has something to do with running at 75hz
@FlorianMargaine hahah exactly :P one of my fav murica memes
 
@Catgocat I don't understand what you're asking there
 
and the only colors I need is red white n blue
 
9:05 PM
wait i'm going private with u
 
oh damn a/s/l straight to private.
 
how does one go private with people yall ?
 
14/m/moon
 
@Catgocat not on this chat
 
@Catgocat I can make it happen
 
9:06 PM
@NickDugger pm plis4cyber
 
make it happen
then
 
@NickDugger 63/m/your back yard
 
I dont do private ._.
 
come on I have high budget
 
I'm more of a voyeur
 
9:06 PM
@Catgocat Who do you want?
 
you have high brain 2
 
@Loktar I have the DK1. For the emulator, should the CV1 have low persistence (less blurry)
 
ok nevermind cat
 
lol
 
we share the same name, aah thats cute
 
9:07 PM
@taco yeah the cv1 is supposidly going to be 90hz and low persistance
but! the vive is out this holiday season
 
Badger !== Catgo
 
but whennn
 
and what devs have been saying is awesome
I'm really excited for it
comes with motion controllers and everything
 
Nice
I should probably sell my DK1 soon then
 
Im going to keep mine forever so I can show my grandkids
and we can all laugh and try it and throw up
and laugh some more.
 
9:08 PM
`function derp() { return 'herp-es'; }

var x = derp; x() // 'herp-es';

derp.call
// function call() { [native code] }

var y = derp.call;
y(); // error wtf man :(
`
 
@Loktar makes me think of southpark
 
did they do a VR ep? I never watch south park
I should though everytime I do I find it hilarious
 
They probably did, but I don't watch it much myself. They do like to have the characters vomit all of the time, though
 
@Catgocat The difference between x.foo() and y = x.foo; y() is that this has a different value.
 
okay, got a dumb mongo question again...
 
9:11 PM
mongo still sucks
 
@Retsam and why should that influence .call ????
 
I remember an episode where one of the dads spent like 5 real-life minutes shitting and vomitting into a trashcan
 
derp.call doesn't exist as a function
You're talking about the prototype method call
 
oh no ?
var y = Function.prototype.call.bind(derp);
got it
 
@Catgocat Because .call must rely on the value of "this" to determine what to call.
 
9:12 PM
@Shmiddty Has to be Randy Marsh, surely
 
You can use y = derp.call.bind(derp), too.
 
@KendallFrey yep
 
<3 bind
 
thank you yall
 
or maybe it was kenny's dad
I can't remember
!!afk hunger
 
9:16 PM
// I have this
> Dogs.find({}, { fields: {"breed": 1, "origin": 1} });
{
  "breed": "German Shepard",
  "origin": {
    "country": "Germany",
    "year": "1891"
  }
}
// I want this
{
  "breed": "German Shepard",
  "country": "Germany",
  "year": "1891"
}
 
Dawgs
 
@corvid So map from the first syntax to the second?
 
is that an efficient solution? Does it return a cursor?
 
@Catgocat hey cool guy
 
hey fancy
 
9:19 PM
I wonder if anyone has ever exhibited a collection of works based on Xzibit.
 
@SterlingArcher Make this work: var y = [].reduce.call.bind([].reduce);
 
no thanks :D
 
man, lucky charms are still delicious
 
ugh man.. I had a bowl of those like 2 weeks ago, bag was at like 25%
all the marshmallows were gone!
my kids picked them out, I seriously got 2 in the entire bowl
I was like "Who even does that!" ofc they found it pretty funny.
Until I told them we weren't getting new cereal until that box was empty :P
 
9:25 PM
#DadProbs
That's why you keep a special box all for yourself
Or just buy a bag of marshmellows (yes, they do that) and keep it on reserve for when it happens again
 
user3949359
function one () {};
one.prototype.hello = "hello";
function two () {};
two.prototype = Object.create(one);
two.hello
// ->undefined
 
user3949359
I don't get why the latter doesn't inherit the prop
 
Because you have to do Object.create(one.prototype)
 
@SterlingArcher lol I've been doing that
 
user3949359
@Catgocat I tried this as well, still undefined
 
9:31 PM
I smell lucky charms now, but I know they're not nearby and I'm not falling for it
 
because ur not creating any instance
of two..
two.hello is the property of the function two
var instance = new two(); instance.hello // 'hello'
 
user3949359
@Catgocat I see, it works now
 
I wish my tech team had an office kinda split away from the main office. Because whenever we talk about stuff work related, everybody looks at us because they don't know half the words we're talking about
oh ffs I'm hitting the itchy beard stage >.< This week is gonna suuuuuck
 
solution: don't shave. noob.
 
9:36 PM
@NickDugger well I'm "shave sculpting"
aka I'm growing a beard but keeping it "tight"
edgewise sorry, it's gonna be a manbeard once it's appropriately lengthed
 
when ppl ask at interviews the years of experience, what do they really mean?
i've never understood this
 
I mean its the years that you've been programming
or the years that you have been working as a programmer?
i mean at a job
 
Professional experience usually
 
what does professional mean?
 
9:39 PM
job
Doesn't matter if you're an entry level programmer on day 7. You have had one weeks professional experience
I've been programming for 4 years now, but I only have 1.5 years of professional experience
 
cool
 
user4330208
Any of you guys know why Chrome gets a literal muffin icon next to it in my task manager? This crap is getting old.
 
i've been for 5 but stopped copy pasting for 3
 
user4330208
I can't code with that.
 
whats wrong with the cupcake
 
user4330208
@SterlingArcher Any idea how to get rid of it?
 
he just gave u the link
 
> Unfortunately, there’s still no ability to revert to the original Chrome icon or turn the feature off completely.
read u sum link son
 
user4330208
...
 
user4330208
9:42 PM
You guys have that too?
 
user4330208
BTW mine looks different than in the link.
 
hm
 
user4330208
I'm done with Chrome if we can't remove it.
 
put a post-it there
 
user4330208
 
It's just a cupcake
 
true
@Sterling Do you recommend any javascript book? Nothing too basic though
 
@Catgocat to be honest I've never read a JS book
But I hear "JavaScript: The Good Parts" is a good book
 
already read it
 
Then I dunno, read the MDN lol
 
9:45 PM
@Sterling do you play codewars?
 
Nah, what's that?
 
user862319
I blame the cupcake on Douglas Crockford.
 
it's a very cool website that is basically a network of programming challenges (it supports tones of languages, including js)
it's much more than u'd expect of a coding website
 
I have not been impressed by CodeWars
 
like if there is a better site
 
9:48 PM
Gotta love the quotes in the EloquentJS book.

Yuan-Ma said, ‘When you cut against the grain of the wood, much strength is needed. When you program against the grain of a problem, much code is needed.’

- Master Yuan-Ma, The Book of Programming

Too bad, I looked up the book, and it doesn't exist. Lol.
 
we even have a SE clan
 
@SomeKittens What about codecombat ? lol I get them both confused.
 
whats that?
 
I don't get it, my code passes the test but when I submit it it fails
 
9:50 PM
Its for kiddies
 
thats because ur code is broken
if it gives submission timed out, just try again
 
@ApathyBear CodeCombat is a different matter as it's open-ended
I'm a bit biased, I was in the crowd when they got accepted into YC. Was REALLY cool
 
codecombat.. is it a joke?
 
No? Was it funny to you?
 
very much indeed
 
9:51 PM
But things like CodeWars are nothing more than a warmup. Would you judge a football player by how good his jumping jacks are?
 
how the hell do you submit a solution?
 
you click the submit button
 
@SomeKittens I agree, I did a few CodeWars in python, and all it really taught me was some optimized tricks
 
I did that
 
just go to another challenge then
refresh the page
 
My test ran fine, my submit failed
 
and if it doesnt work reinstall windows
 
I like exercism.io, but I don't get enough Nitpicks :(
 
9:54 PM
do you codewars apathybear?
 
No, lol.
 
@SterlingArcher why do you go the hard way and don't just do function Foo(v) { return { val: v }; }?
 
I used to
 
he likes it hard
 
@FlorianMargaine that was just there by default
 
9:55 PM
Sterling join the clan when ur done Account settings > Clan > Type "Stack Exchange" (without quotes)
 
I'm probably not going to continue
 
k
 
Well I guess I'm dumb
 
@SomeKittens thats my favorite video to leave on repeat! :P
 
10:00 PM
function factorial (n) {
  var total = 1;
  for (var i=1; i<=n; i++) {
    var add = i*total;
    total += add;
  }
  return total;
}
I thought this was a proper factorial function lol
 
@SomeKittens nice, although I'm not as divisive
 
@BenjaminGruenbaum Some of them are a bit old
But it's a useful metric, not the be-all-end-all
 
@SterlingArcher Are you still on codewars or u gave up?
 
I just want to solve this one factorial problem
 
@SomeKittens yeah, I agree.
 
user4330208
10:06 PM
I re installed and chrome still has a muffin. Time to reformat?
 
@SterlingArcher 1 factorial is 1
 
yeah I think I misread the question
 
@SterlingArcher If you have the time do this codewars.com/kata/sequences It's made by me
 
@SomeKittens it's a really old debate (inheritance vs composition), the conclusion is almost always that composition wins in almost any case.
 
Suggestions bitte? How could I make this more dynamic? let controller = require('../controllers/' + route.controller); -- It's in my router. Right now, it requires your handlers to be in a controllers folder. Is this 'bad'?
 
10:09 PM
It's just having members that contain the functionality instead of inheriting :) In JS it's also common to mixin things.
(That is, just copy properties over)
!!afk sleep
 
function factorial (n) {
    if (n == 1) return 1;
    var total = 0;
    for (var i=1; i<=n; i++) {
        if (i+1 <= n && total==0) total += i*(i+1);
        else if (i+1 < n && total>0) total += total*(i+1);
    }
    return total;
}
What am I doing wrong here?
 
if n < 1 return 1
 
factorial(5) returns 240, not 120
 
<= 1
 
Good call, factorial(0) is also 1
 
10:22 PM
why all that mess with factorial? god
 
I'm not good with math
 
function factorial (n) { return n < 2 ? 1 : n * factorial(n - 1); }
that should do it.. and give false output for negative nums
 
Can you explain it to me?
 
Yes
wait
let me write
 
Actually, if you can rewrite it in a non-terniary I'd understand it better
 
10:25 PM
function factorial(n) {
if (n < 2) return 1;
return n * factorial(n - 1);
}

/*

Factorial is multiplication of numbers from 1..N,

3! = 1 x 2 x 3

Therefore the function goes 3 * factorial( 3 - 1)

3 * 2 * factorial(2 - 1)
3 * 2 * 1;


*/
it stacks up till it reaches 1 and then returns
 
Ah duh, it's recrusive
 
yeah but u could make it iterative so it doesnt crash with large numbs
 
Thanks for explaining
 
One day we'll have proper tail recursion in JavaScript...
 
@monners We can make a trampoline and turk recursion
its called turk right?
 
10:28 PM
!!afk home
 
@Catgocat Or we could make margaritas and complain about how everything is broken :D
 
I don't think it'll overflow the stack for numbers that fit into floats anyway
 
Kata teaching tail recursion with trampoline in js
 
@Catgocat I appear to have done that one... Musta been a while back
Wait, no I haven't. Derp.
 
10:29 PM
@Sterling `function factorial(n) {
var final = 1;
while(n) final *= n--;
return final;
}`
@monners It's actually an iterative solution that looks like tail recursion
@SterlingArcher `function factorial(n) {
return Array.apply(null, Array(n)).reduce(function(p, c, i) {
return p *= (i+1);
}, 1)
}`
 
@Catgocat SterlingArcher is afk: home
 
!!tell catgocat format
 
@catgocat Format your code - hit Ctrl+K before sending and see the faq
 
function(){}
nice
function one() {};
one.prototype.hello = 'hello';
function two() {};
two.prototype = Object.create(one.prototype);
!!tell Shmiddty ty
 
@Catgocat Command ty does not exist. Did you mean: to (note that /tell works on commands, it's not an echo.)
 
10:35 PM
-.-
!!afk c
 
10:47 PM
@KendallFrey pingola
 
pongila
 
Re: Building rockets
I used to just throw Mainsails on everything but your comment made me realize I was making everything more difficult.
Do you have a tl;dr (or a link) on building better rockets (i.e. what numbers I should be aiming for)
 
hmmm
Just make them as small as possible
know your delta-v margins, and don't add any extra
 
Yeah, the Delta-V-to infographic has been really useful
 
it's not a bad idea to avoid filling fuel tanks full if you don't need it
especially on upper stages
a ton of weight saved on your payload is tens of tons of rocket saved
in terms of saving money, the main thing you would care about is you can possibly lift a lighter rocket with a cheaper engine
 
10:56 PM
I'm only on science mode
Otherwise I'd be out of cash ages ago
 
rockets are pretty cheap in KSP
 
I think I've gotta get back into KSP
 
I should start
like tonight maybe
but I'm programming, so maybe not
 
11:12 PM
function ipToInt32(ip){
  return ip.split('.').reduce(function(a, b, i){
    return a | (b << (8 * (3 - i) - 1));
  }, 0);
}
It's overflowing. :(
 
ok, rfc 3987 is insane
 
> Please refer to the current edition of the "Internet Official Protocol Standards" (STD 1)
chuckles like a little girl
 
seriously
here is the list of regexes to validate this shit in python: github.com/dgerber/rfc3987/blob/master/rfc3987.py#L131-L269
 
<li><font color="#f17b05"><font color="#f17b05"><font color="#f17b05">.....</font></font></font></li> sigh...
 
hell yeah font tag
 
11:16 PM
Someone really wants it to be orange
 
Oh god.... There's more
 
orange is the best color anyway
@monners bgcolor?
 
<li align="LEFT"><font color="#f17b05"><font color="#f17b05"><font color="#f17b05"><font color="#f17b05"><font color="#f17b05"><font color="#f17b05">.....</font></font></font></font></font></font></li>
 
I don't know what the hell Setalux is, but it better be orange
 
Sorry, probably should have removed the clues to what I'm working on before hitting enter
 
11:17 PM
can you private message someone on this chat
 
@chronotrigga Sorta, you can open a new chat room with a user
 
it's ok, I don't know what it is, and I don't really care
 
How many times are people gonna ask that in here?
 
i see
 
@NickDugger until SO implements the feature?
 
11:18 PM
What are we, illuminati?
 
@Shmiddty Append >>> 0
 
@NickDugger Well... yes.
 
And the -1 is incorrect, I think
 
@copy What's this doing?
 
Convert to uint32
function ipToInt32(ip){
  return ip.split('.').reduce(function(a, b, i){
    return a | (b << (8 * (3 - i)));
  }, 0) >>> 0;
}
 
11:20 PM
given a buffer, what can I do with it besides converting it to a string? (currently, I'm assuming that all posts are sending JSON)
 
JavaScript is atrocious
 
your mom is
 
lol
function ipToInt32(ip){
    var aips = ip.split('.');
    return ((((aips[0]-0) << 24) >>> 0) + (((aips[1]-0) << 16 ) >>> 0) + ((((aips[2]-0) << 8)) >>> 0) + (aips[3]-0) ) >>> 0
}
function ipToInt32(ip){
   return ip.split(".").reduce(function(int,v){ return int*256 + +v } )
}
Apparently that works as well
 
stop paying attention to not my questions
 
make a kata
 
11:23 PM
I don't know what that is
 
All solution are terrible
 
Your turn!
 
::::(((((((((((((((((((9
 
function ipToInt32(ip)
{
    var ip = ip.split(".");
    return (ip[0] << 24 | ip[1] << 16 | ip[2] << 8 | ip[3]) >>> 0
}
 
11:28 PM
Ok, that's better. You win
 
now kiss
 
( ˘ ³˘)♥
 
I'm paying $10 paypal to someone who can correctly add a single line of code in my javascript functions pulling data from a MySQL database (I can't figure it out unfortunately)
The code is already there I just need an additional table
 
Anyone know a good way to split() on multiple separators?
something like this: astring.split(new RegExp('\n') && " ")
But obviously that doesn't work
 
@chronotrigga Make it $100 and you'd have better luck
 
11:37 PM
lol I would but I know it only takes 5 minutes for someone who knows js
 
Nobody bills less than an hour.
 
what does javascript have to do with creating a database table?
 
@chronotrigga You're not paying for the time, you're paying for the expertise
 
It's a waste of time
 
in that case, I'd gladly give 100 if you can help me solve other problems
 
11:38 PM
only if you call me daddy
 
hahaha
 
and it's a web app but someone else made it and I'm not familiar with his code
 
How much are you getting paid to work on this code?
 
just a new project for work so technically included in my hourly.. js isn't my field -- i tried to duplicate the code to add the table but somethings amiss
i tried several options for 5 hours so i've really been struggling
 
So what's your hourly wage?
 
11:50 PM
about 20 an hour
 
what country?
 
usa, but i don't really do js i'm css/mysql/php
 
crl
looks like you don't like js
 

« first day (1635 days earlier)      last day (3306 days later) »