Open Side Menu Go to the Top

06-03-2016 , 01:55 PM
Quote:
Originally Posted by RustyBrooks
I think they might mean something like what we have here, where we have a local repo of all the npm packages we use, and they get installed from there. npm requests don't leave our network. (and holy **** do we use a lot of npm packages. Thousands?)
So if you add a new NPM package - your local repo just goes out and gets it from NPM.com right?
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD **
$25m Guaranteed WPM on CoinPoker
Join the action now
Daily Rewards • Splash Pots • CoinRaces
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD **
06-03-2016 , 02:02 PM
Quote:
Originally Posted by suzzer99
So if you add a new NPM package - your local repo just goes out and gets it from NPM.com right?
I honestly don't know. Probably. This is still safer than getting it from some unknown repo every time

* better performance
* protects you from packages "disappearing" or changing unexpectedly
* protects you from malicious interference

Basically, you only have to get it "right" one time, instead of from now until perpetuity.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 02:53 PM
lol @ npm whitelist can you imagine?
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 02:58 PM
Especially if it included submodules - which logically it should.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 02:59 PM
It seems to me that the javascript library market is extremely fractured and I don't really understand why. Like... there are libraries that do a single string function, right? Like reverse a string or replace tabs with spaces or dumb stuff like that? But not so much "here is a single library that does all the string stuff you want"?

Because I can't figure out, otherwise, how it is that we literally have more than a 1000 npm packages to install. (Our python package footprint is more like 20 and most of them do something very specialized, like, say, implement oauth or something)
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 04:22 PM
The other day, I got contacted by a recruiter looking for a full-blown PostgreSQL and MySQL DBA. Uh... sure, why the **** not? I tell the recruiter that I'm not a DBA, sorry.

Today, we chat, but turns out they don't really need a DBA, just someone who can do a bit of SQL and a bit of DevOps, which means talk to developers and stuff.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 05:03 PM
well there's a first here I go using Math.sin() which unfortunately does not return 666.

You know you've coding too much when you start trying to end your sentences with ; instead of .
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 05:29 PM
And after Math.tan I remain as pale as ever

(Just kidding. I am a dark nut brown at all times)
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 05:34 PM
I ran Math.cos() and this appeared:

NSFW
Spoiler:



Dammit I just searched furry cosplay fetish on my work computer. Wasn't on the VPN though, so it's probably good.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 05:44 PM
**** how do I make an acceleration curve lol I never got past AP calc 1!
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 08:18 PM
Quote:
Originally Posted by Grue
**** how do I make an acceleration curve lol I never got past AP calc 1!
You don't (really) need calculus for it. What are you looking for? That is, what is your x-axis and what is your y-axis? Is the acceleration constant?
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 08:32 PM
Quote:
Originally Posted by Grue
**** how do I make an acceleration curve lol I never got past AP calc 1!
y (distance) = initial displacement + velocity*x + 1/2acceleration*x^2 (x = time)

Do you have the velocity and acceleration and need to solve for distance?

Last edited by suzzer99; 06-03-2016 at 08:38 PM.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 08:44 PM
I just wanted a vertical curve from point a to point b to point c that's the same as a while moving at a consistent horizontal velocity. Took a while but worked out fine as

{{point a height}} - {{point a height}} * Math.sin((Math.PI) * {{percentage of difference between start of time to full time in (0.0 to 1.0) format }})

but damn if I knew what sine was for the last 20 years.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 09:14 PM
You are in an interview setting with a live coding exercise (live online editor or whiteboard). Lets assume you know the 'idiot proof solution' and the 'elegant but more complex solution' to a problem. Which one do you present to your interviewer and why?
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 09:26 PM
Always present the elegant and more complex solution. They wanna be impressed by "your chops".

One job interview they had some group of objects they wanted to put in random order. I just put them in a map and did myObject.keySet() to get a quasi-random order list of the group of objects. They wanted to hire me on the spot and made a really strong play. The boss guy was so excited by my novel solution.

Nevermind that this will give the same result every time so it's not really that random. I did mention that after I'd done it and thought about it a bit. They didn't care.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 09:27 PM
Quote:
Originally Posted by Craggoo
You are in an interview setting with a live coding exercise (live online editor or whiteboard). Lets assume you know the 'idiot proof solution' and the 'elegant but more complex solution' to a problem. Which one do you present to your interviewer and why?
My answer to this has evolved over the years. I don't know if it's a function of age/experience, but when I was younger, they wanted *any* solution, just wanted to know I was basically competent. These days, if I give the easy/obvious solution, it's a waste of time, they want the good one. There are very few cases where I've been given a whiteboard problem where there wasn't a known good solution.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 10:27 PM
Quote:
Originally Posted by suzzer99
Always present the elegant and more complex solution. They wanna be impressed by "your chops".

One job interview they had some group of objects they wanted to put in random order. I just put them in a map and did myObject.keySet() to get a quasi-random order list of the group of objects. They wanted to hire me on the spot and made a really strong play. The boss guy was so excited by my novel solution.

Nevermind that this will give the same result every time so it's not really that random. I did mention that after I'd done it and thought about it a bit. They didn't care.
I always like to 7 as a random number.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 10:40 PM
Quote:
Originally Posted by kerowo
I always like to 7 as a random number.
How about using base 16 ^ Math.round(Math.random())

Something like...

(7).toString(16 * Math.round(Math.random()))

That'll stop 'em in their tracks
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 11:43 PM
I just spent 30 minutes on the phone with my dad walking him through copy-pasting. I think he's finally getting it this time! He's very motivated because he has some publisher who's supposed to publish his poems.

Only problem is I'm having him Ctrl-A from other documents, and he still doesn't know how to select text. Baby steps. I only got the speech about how he's right brained and not left brained for a few seconds this time.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-03-2016 , 11:59 PM
Other fun things:

My Dad said Ctrl-A didn't do anything. I just immediately knew that he was hitting Ctrl then A, not both at the same time. I am getting good at this. A few months ago I walked him through changing his home page on Chrome. Don't try this at home kids.

I've taught him not to be terrified that Ctrl-A turns everything blue. He only thinks about the print version and he was afraid it would all be blue.

I just taught him how to close windows. He calls it "X them out". Not sure how he was ever closing anything before. I think he just keeps opening things then shuts down his computer when he's done.

Sometimes you forget just how foreign computers are to some people (old usually). The scary thing is my Dad knows infinitely more than Trump - who's never touched a computer in his life.

Last edited by suzzer99; 06-04-2016 at 12:10 AM.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-04-2016 , 12:00 AM
Quote:
Originally Posted by suzzer99
I just spent 30 minutes on the phone with my dad walking him through copy-pasting. I think he's finally getting it this time! He's very motivated because he has some publisher who's supposed to publish his poems.

Only problem is I'm having him Ctrl-A from other documents, and he still doesn't know how to select text. Baby steps. I only got the speech about how he's right brained and not left brained for a few seconds this time.
I have equally gifted parents. I gifted them my old iphone when i got a new one. I explained to them how easy it is to record videos then upload them to youtube (explaining that some people make a great deal of money if their channel gets tons of views). They were interested as long as they didn't have to do anything. That led me to think... "Wouldn't it be awesome if I could create a script [i was thinking Python] which would upload every video in a predefined folder to youtube." The idea is they would just double click on a Python script and everything else is done for them. Maybe you could do something similar in your case?

Edit : parents are retired so any income they make as a result of hobbies is a bonus
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-04-2016 , 02:11 AM
Just watching the latest episode of Silicon Valley - the lead basically dumps a new girl because she uses tabs over spaces and VIM over EMACS. So well done - they have some serious techies writing for the show.

Also apparently he indents 8 spaces with his tabs - which I just can't even imagine. My new job has 4-space indents and I want to stab myself in the eye. 2 spaces 4 life!
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-04-2016 , 02:14 AM
God that show is so on the mark this season
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-04-2016 , 02:16 AM
I'm just at the part where Dinesh improves the video chat and the girl is disappointed when she sees him. So heartbreaking. Between that and the tabs vs. spaces break up, I have a sad.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
06-04-2016 , 02:44 AM
Quote:
Originally Posted by suzzer99
Just watching the latest episode of Silicon Valley - the lead basically dumps a new girl because she uses tabs over spaces and VIM over EMACS. So well done - they have some serious techies writing for the show.

Also apparently he indents 8 spaces with his tabs - which I just can't even imagine. My new job has 4-space indents and I want to stab myself in the eye. 2 spaces 4 life!
2 pace 'tabs' and i can hardly tell wtf is tabbed. 4 minimum imo.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD **
$25m Guaranteed WPM on CoinPoker
Join the action now
Daily Rewards • Splash Pots • CoinRaces
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD **

      
m