These are chat archives for MontCode/GeneralChat

1st
Jul 2016
Lily Romano
@Lilyheart
Jul 01 2016 00:44

The best part of the image feed on this site for this user is the caption he posts on totally unrelated images.

Push to Production
push to production

Eric Phy
@SimplyPhy
Jul 01 2016 01:09
like
I'm in a few groups that just send absurdities and/or obscenities via gif/meme
basically all day
Victor
@VictorHall
Jul 01 2016 01:52
Any recommendations for api's for general data on people, places, things???
Lily Romano
@Lilyheart
Jul 01 2016 01:52
i have a resource that might help, just a sec
Victor
@VictorHall
Jul 01 2016 01:52
@davidjcastner @Lilyheart @SimplyPhy
Victor
@VictorHall
Jul 01 2016 01:54
oh yea thanks
Lily Romano
@Lilyheart
Jul 01 2016 01:54
first place i go for APIs
Mike
@dcpking
Jul 01 2016 02:23
And the middle one's name is Sid!! How purrfekt!
Eric Phy
@SimplyPhy
Jul 01 2016 13:37
morn' :)
Lily Romano
@Lilyheart
Jul 01 2016 13:37
sup
Eric Phy
@SimplyPhy
Jul 01 2016 13:38
@VictorHall try wikimedia api
holla
did you get more than 2 hours of sleep?
Lily Romano
@Lilyheart
Jul 01 2016 13:39
more than 2! I kept waking up tho, but I was able to keep going back to sleep. It’s better!
Eric Phy
@SimplyPhy
Jul 01 2016 13:41
success!
Eric Phy
@SimplyPhy
Jul 01 2016 14:05
hmmm...I tried to use a sudo command in terminal yesterday to get Sass, and it asked for me to login, and I didn't get my password in, and then my computer died. Now I'm trying to push my repo to github, and it's returning a 403 error saying permission is denied...any way I can log back in, or something?
Lily Romano
@Lilyheart
Jul 01 2016 14:07
sudo in terminal has you log into your computer with administrative access. It’s not related to a github login.
can you paste exactly the error you are getting when you try to push?
Eric Phy
@SimplyPhy
Jul 01 2016 14:08
Phy (master) retain $ git push origin master remote: Permission to udacity/ud989-retain.git denied to SimplyPhy. fatal: unable to access 'https://github.com/udacity/ud989-retain.git/': The requested URL returned error: 403
oh
it looks like that might be the address for udacity's version of the repo
weird that it would be though, since I used the same command yesterday to push it to my own..
Lily Romano
@Lilyheart
Jul 01 2016 14:10
yeah, you need to change the address of your repo? git remote -v should tell you what your current settings are.
Eric Phy
@SimplyPhy
Jul 01 2016 14:10
huh.
I wonder how they got switched around
Lily Romano
@Lilyheart
Jul 01 2016 14:11
Do you need the command to change the address? If so, what does it say when you git remote -v?
you might have an origin and an upstream
Eric Phy
@SimplyPhy
Jul 01 2016 14:12
I'm searching that via git docs
also, what are the specs you want for the montBot logo?
dimensions, ppi, type of image, etc
Lily Romano
@Lilyheart
Jul 01 2016 14:13
either way, you’ll need to type in git remote -v to understand what you currently have setup to know what to fix
Eric Phy
@SimplyPhy
Jul 01 2016 14:13
yeah I used that, thanks @Lilyheart :D
it has fetch and push set to the udacity repo
Lily Romano
@Lilyheart
Jul 01 2016 14:14
origin on the left?
Eric Phy
@SimplyPhy
Jul 01 2016 14:14
yup
oh haha
i know the problem!
Lily Romano
@Lilyheart
Jul 01 2016 14:14
in the wrong folder?
Eric Phy
@SimplyPhy
Jul 01 2016 14:15
ha I forgot I even cloned that repo; I was thinking it was my cat clicker premium, and i git status and saw there were uncommitted changes, so I was like oh well might as well push them xD
<--idiot
Lily Romano
@Lilyheart
Jul 01 2016 14:16
I know I need to go through all my locally cloned repos and clean that up. But I think I might have solved that.
Eric Phy
@SimplyPhy
Jul 01 2016 14:16
nice
oh well, I learned something from it :D
Lily Romano
@Lilyheart
Jul 01 2016 14:16
I think I’m just going to start using c9 and delete the workspace when I’ve pushed and I don’t think I’ll be using it anymore. What you think @davidjcastner ? Also let me use all my various machines without worry about who has what and what has been pushed when.
Eric Phy
@SimplyPhy
Jul 01 2016 14:16
so horray!
Lily Romano
@Lilyheart
Jul 01 2016 14:16
I bet 99% of all Git Gurus have done that exact thing before.
what OS are you using?
Eric Phy
@SimplyPhy
Jul 01 2016 14:16
you're talking to me yes?
Lily Romano
@Lilyheart
Jul 01 2016 14:16
yup
Eric Phy
@SimplyPhy
Jul 01 2016 14:17
macOS atm
i use windows 10 at home, but that's mostly for gaming/design work
actually the mac is gradually taking over everything except gaming, though I have no time for games anymore :sad face:
Lily Romano
@Lilyheart
Jul 01 2016 14:17
Git for Windows is by far the best bash git I’ve ever used. So much nicer.
For mac, the stuff listed here has made GH much more helpful (but the edits to the bash profile are a little out of date)
Lets me even see what branch I’m currently on.
i’ll get a screenshot
Eric Phy
@SimplyPhy
Jul 01 2016 14:21
I prefer doing more "risky" comp stuffs with mac, just because i find it much harder to break, and when problems arise, I can actually dig into the os files and they're readable; unlike windows services, dlls, and the insane registry
David Castner
@davidjcastner
Jul 01 2016 14:21
you mean c9 vs putty?
Eric Phy
@SimplyPhy
Jul 01 2016 14:21
it's funny, as far as hardware goes, mac is utterly inflexible, but as far as software goes, it's so much less intimidating that windows
Lily Romano
@Lilyheart
Jul 01 2016 14:22
Guess it’s what you are familiar with. It’s easier for me to fix windows issues. But I’ve been using it since 3.1 xD
Eric Phy
@SimplyPhy
Jul 01 2016 14:22
software as in like OS system
Lily Romano
@Lilyheart
Jul 01 2016 14:22
@davidjcastner I just mean c9 vs coding locally
David Castner
@davidjcastner
Jul 01 2016 14:22
oh c9 doesn't have atom instant lose
Lily Romano
@Lilyheart
Jul 01 2016 14:22
yeah, but I can still put files in atom :p
Eric Phy
@SimplyPhy
Jul 01 2016 14:22
I started a small computer repair company a couple years back, and mac issues were either 100% impossible to fix, or wayy easier to fix than major windows issues
so many different things can go wrong with windows, and it can be really hard to pin down
David Castner
@davidjcastner
Jul 01 2016 14:23
My solution is store everything online and when something goes wrong reinstall the os
Eric Phy
@SimplyPhy
Jul 01 2016 14:24
yeah that tends to do it; but when working with others comps, they don't usually have full backups of critical files
Lily Romano
@Lilyheart
Jul 01 2016 14:24
Yeah, roommie works in IT infrastructure at Jefferson medical. It’s all rebuild machines. heh
Eric Phy
@SimplyPhy
Jul 01 2016 14:24
anywho: @Lilyheart thoughts of logo specs?
David Castner
@davidjcastner
Jul 01 2016 14:24
let's just say I don't enjoy IT work
Lily Romano
@Lilyheart
Jul 01 2016 14:24
Not right now. Brain be somewhere else.
Eric Phy
@SimplyPhy
Jul 01 2016 14:24
I neither
Lily Romano
@Lilyheart
Jul 01 2016 14:24
Me either! Does make for one point of smooth sailing in the house. Complementary skill sets
David Castner
@davidjcastner
Jul 01 2016 14:25
And I absolutely despise windows
Lily Romano
@Lilyheart
Jul 01 2016 14:25
I’m being bad today. I’m still sitting in bed on my macbook eating a piece of chocolate for breakfast.
David Castner
@davidjcastner
Jul 01 2016 14:25
windows < mac < linux
Lily Romano
@Lilyheart
Jul 01 2016 14:25
I dislike windows as well, but I love gaming, so that softens it from despite to just dislike.
But, with windows going the way it is, I’ve been moving to more console gaming lately.
Eric Phy
@SimplyPhy
Jul 01 2016 14:27
I actually really like windows 10; it's multitasking is actually better than mac, imo. That said, I still won't mess with it too much; i'd hate to deal with a major problem :(
I jacked up my cpu and/or mobo a little bit by benchmarking the cpu shortly after puttting the thing together...works fine, just takes anywhere between 1 and 20 tries to turn the damn thing on
it's the stranged thing; I haven't been able to figure it out so i gave up
works great when it does turn on
Lily Romano
@Lilyheart
Jul 01 2016 14:29
I only have 10 on one machine. Kodi (the tv computer). It’s been removed from pretty much every other computer. It’s fine as long as you don’t mind the OS making changes without your permission including uninstalling software.
Smooth sailing on my win7 and win8 machines.
with VirtualBox on the PC (the win7 machine) for any yummy linux needs.
Eric Phy
@SimplyPhy
Jul 01 2016 14:31
yeah, actually a couple days ago i turned the comp on and a windows service was using like 99% disk out of nowhere; comp was completely frozen almost, and it's 1tb ssd. I researched it and found out it was a windows service that came with an autopatch that uploads tracking files to microsoft
Lily Romano
@Lilyheart
Jul 01 2016 14:31
all without your knowledge or permission outside of the blanket permission you allowed when installing the OS that says bitch we own you
Eric Phy
@SimplyPhy
Jul 01 2016 14:32
it was funny, there was one dude that just kept posting in a microsoft forum about it, constantly reiterating that it was malware
Lily Romano
@Lilyheart
Jul 01 2016 14:35
well, it is, but malware he allowed with blanket permissions.
Eric Phy
@SimplyPhy
Jul 01 2016 14:39
@Lilyheart fav games?
Lily Romano
@Lilyheart
Jul 01 2016 14:43
I like games in too many categories to pick one. I have a few dislikes tho that cut out big categories. I don’t like gun games (aka FPS) and horror + anxiety doesn’t mix well so I can very rarely play them. Not saying I’m anti-violent games tho. Give me a sword, or a bow, or magic and I’m happy to kill swaths of goblics or orcs or wolves or whathaveyou.
Only thing I’ve currently been playing tho is The Witness (I’m late to that game) and Two Brothers (I think it’s called).
And Minecraft ofc
Eric Phy
@SimplyPhy
Jul 01 2016 14:46
I own Two Brothers (i think...that's the one where you control both at the same time, right?), but I haven't played it yet.
1- Zelda: Ocarina of Time
2- Starcraft: Broodwar
3- Diablo II
4- Super Mario 64
4- SSB: Brawl
4- Goldeneye 007
5- Mass Effect 2
6- Dragon Age: Origins
6- Mario Kart 64 & Wii
7- Donkey Kong Country
8- Starcraft 2
8- Borderlands 1 & 2
9- Dota 2
10- Dragon Age: Inquisition
Lily Romano
@Lilyheart
Jul 01 2016 14:46
yes. the puzzle mechanics in that game is amazing
Eric Phy
@SimplyPhy
Jul 01 2016 14:46
that's my list
Lily Romano
@Lilyheart
Jul 01 2016 14:47
Not a single final fantasy. I am disappoint.
Eric Phy
@SimplyPhy
Jul 01 2016 14:47
ha literally never played one
Lily Romano
@Lilyheart
Jul 01 2016 14:47
we can no longer be friends.
Eric Phy
@SimplyPhy
Jul 01 2016 14:47
never was a playstation'er, and never discovered them for pc
Lily Romano
@Lilyheart
Jul 01 2016 14:48
tho ++ on the zelda. I have a few zelda shirts. The best is probably link standing holding a map looking very confused with mario type world behind him.
Eric Phy
@SimplyPhy
Jul 01 2016 14:49
I updated my list just now; gitter reset the numbers because they were in ol format
ha nice
Lily Romano
@Lilyheart
Jul 01 2016 14:53
I come out into the living room and I'm being scolded by the birds outside because the feeder is empty. Mama Cardinal is pissed.
Eric Phy
@SimplyPhy
Jul 01 2016 14:56
and that's what cats are for xD
so the bastards at Udacity are making me re-create cat clicker again
Lily Romano
@Lilyheart
Jul 01 2016 14:56
The cats like to watch the birds.
And now I'm wondering if I'm too old for a bed fort.
Eric Phy
@SimplyPhy
Jul 01 2016 14:56
this time with a pseudo-ajax style
Jonathan Herman
@lantech19446
Jul 01 2016 14:56
ok so I have a really weird question, if I write a function in JS normally when I call that function it's going to run all the steps within it. Is there a way to select certain steps within a function? I don't even know if this would ever be practical but I'm listening to the videos and just thought of it
Lily Romano
@Lilyheart
Jul 01 2016 14:56
practice practice practice.
What do you mean by select? Like a debugger and step through the code?
Eric Phy
@SimplyPhy
Jul 01 2016 14:57
sure, make it the property of an object, and break the function into parts, calling the properties whenever they're needed
Lily Romano
@Lilyheart
Jul 01 2016 14:58
If you have a function that is long enough that you want to call only parts of it, than your function is too long.
Jonathan Herman
@lantech19446
Jul 01 2016 14:59
@Lilyheart say I have a function that builds a sandwich and I make one function for 3 types of sandwiches because the only difference is the type of fake meat, is there some way outside of else if statements that I could select say seitan over tempeh
Eric Phy
@SimplyPhy
Jul 01 2016 15:00
sounds like you're contemplating how to implement mvc
Lily Romano
@Lilyheart
Jul 01 2016 15:00
Many ways
Jonathan Herman
@lantech19446
Jul 01 2016 15:00
@SimplyPhy that would definitely be easier I'm just curious about it all being in one function without breaking it up it's just the way my brain is working things out as I watch the videos
Eric Phy
@SimplyPhy
Jul 01 2016 15:01
you can create a switch statement, maybe
?
David Castner
@davidjcastner
Jul 01 2016 15:01
top-down design, break your function into smaller parts
Eric Phy
@SimplyPhy
Jul 01 2016 15:01
conditionals within your function can be dependent upon whatever parameters you call into it
so like:
Lily Romano
@Lilyheart
Jul 01 2016 15:02
@lantech19446 in object oriented program, the hardest thing I've had to learn is to break things down in the small parts.
In the beginning it sounds stupid and backwards. It makes no sense logically. But TRUST me. As things get bigger and more complicated, you will want the small bits.
Eric Phy
@SimplyPhy
Jul 01 2016 15:03
function sammitch(meat){
  if (meat === "manflesh") {
    abort.sammitch;
  } else if (meat === "fish" {
    devour.sammitch;
  }
};
something like that
Lily Romano
@Lilyheart
Jul 01 2016 15:04
or sammitch called another function addMeat and passes the meat option on to it because maybe you also want to make a salad with meat, or pasta with meat.
Jonathan Herman
@lantech19446
Jul 01 2016 15:06
ok makes sense, not sure I could write it myself yet but looking at it it makes sense.
Eric Phy
@SimplyPhy
Jul 01 2016 15:08
that tends to be my issue; the logic part usually isn't challenging; it's navigating the language syntax and the environment (i.e. browser constructs) that's the timestating effort
though the logic part actually often is influenced by the latter elements, and thereby is dependent upon them...so in the end, the logic feels easy, but is really just a part of the challenging efforts
Lily Romano
@Lilyheart
Jul 01 2016 15:10
It's long an pseudo code, but something like this is why you would want to split it up.
//crappy pseudo code ahead
function sammich(options) {
    get.options.bread(2);
    add.options.dressing();
    addProtien(options.protein);
}

function pasta(options) {
    get.options.noodle();
    addProtien(options.protein);
}

function addProten(protein) {
    switch (protein) {
        case seitan:
            //steps to prepare and add seitan
            break;
        case tempeh:
            //steps to prepare and add tempeh
            break;
        default:
            //steps if protien is unknown
    }
}

make.sammich({
    bread: "wheat",
    protein: "seitan",
    dressing: "oil"
});

make.pasta({
    noodle: "rice",
    protein: "tempeh"
});
Jonathan Herman
@lantech19446
Jul 01 2016 15:11
and of course just when I start getting into the videos again and being able to ask questions I have to go setup the christmas in July sale. I'll be back in a bit.
David Castner
@davidjcastner
Jul 01 2016 15:11
hahah @Lilyheart I was putting one together too
Lily Romano
@Lilyheart
Jul 01 2016 15:12
And now when you need to add a meat, you only need to go to addProtein and don't have to remember... what is in sammish and I just called that part from pasta or the other way around...
When it's all in one file, it's not so bad. But when projects start getting big and different parts are in different files... you could be digging (or grep'ing) for days.
Eric Phy
@SimplyPhy
Jul 01 2016 15:14
I hope that's super psuedo; cause while i get the logic, the syntax isn't flowing for me :(
either me dumb or code isn't designed to be functional...in which cause probably me dumb for attempting to make sense of it as if it were designed to be functional
Lily Romano
@Lilyheart
Jul 01 2016 15:15
I disclaimered it as crappy pseudo
Eric Phy
@SimplyPhy
Jul 01 2016 15:15
i saw :D
i think it's nice pseudo
i'm just glad it's pseduo, cause it made me feel like an idiot when i really tried to apply it
Lily Romano
@Lilyheart
Jul 01 2016 15:16
xD just like your devour.sammitch inside of function sammitch doesn't really work.
Eric Phy
@SimplyPhy
Jul 01 2016 15:16
haha what??!!??!!!!!!!?????%
Lily Romano
@Lilyheart
Jul 01 2016 15:16
Your exclaims grew!!!!!!!!!!!!!
heh
Eric Phy
@SimplyPhy
Jul 01 2016 15:17
xD
okay i have to go rebuild catclicker
sigh
Lily Romano
@Lilyheart
Jul 01 2016 15:17
I have a cat you can borrow. He likes clicks.
Eric Phy
@SimplyPhy
Jul 01 2016 15:18
ha i'm sure he does
Lily Romano
@Lilyheart
Jul 01 2016 15:18
imma go make a poached egg I think.
David Castner
@davidjcastner
Jul 01 2016 15:19
@lantech19446 here is an example of top-down design:
var makeSandwich = function(ingredients) {
    // code for building sandwich
    // let's just say this function is thousands of lines of code
    // break into smaller parts
};

// example of how to break it down (not on the dance floor)

var addBread = function(sandwich, breadType) {
    var bread = buyFromBakery(breadType);
    sandwich.add(bread);
};

var addCondiments = function(sandwich, condimentsList) {
    var condiments = stealFromStore(condimentsList);
    condiments.forEach(function(condiment) {
        sandwich.add(condiment);
    });
};

var addBread = function(sandwich, proteinType) {
    var protein = becomeButcher(proteinType);
    sandwich.add(protein);
};

var addVegetables= function(sandwich, vegetablesList) {
    var vegetables = visitLocalFarmersMarket(vegetablesList);
    vegetables.forEach(function(vegetable) {
        sandwich.add(vegetable);
    });
};

var makeSandwich = function(ingredients) {
    var sandwich = new Sandwich();
    addBread(sandwich, ingredients.bread);
    addCondiments(sandwich, ingredients.condiments);
    addProtein(sandwich, ingredients.protein);
    addVegetables(sandwich, ingredients.vegetables);
    return sandwich;
};

makeSandwich({
    bread: "baguette",
    condiments: ["dijon mustard", "sundried tomato pesto"],
    protein: "bacon",
    vegetables: ["romaine lettuce", "arugula", "tomato slices"]
});
you can use a switch statement as @Lilyheart and @SimplyPhy pointed out inside one of the functions if it does something differently depending on the ingredients
Lily Romano
@Lilyheart
Jul 01 2016 15:20
@davidjcastner obviously puts more time into his code. Me? I just wanted to be first for once xD
Jonathan Herman
@lantech19446
Jul 01 2016 15:27
lol ok they both help it's just insane to me that something that seems so simple takes sooo many lines of code to accomplish.
also totally read that wrong and thought that @SimplyPhy was going to work on catlicker not catclicker and went huh???
Eric Phy
@SimplyPhy
Jul 01 2016 15:27
Thoughts on performance contrasts between instantiating functions within a loop vs calling a function from a loop? Does one reliably outperform the other? --note: probz a tough question, though figured i'd give it a go in case someone happens to know the answer offhand.
haha catlicker is a more advanced topic
David Castner
@davidjcastner
Jul 01 2016 15:28
making functions inside a loop is not recommended, it is also slower
Eric Phy
@SimplyPhy
Jul 01 2016 15:30
I just read elsewhere that while it's discouraged via jslint, it actually doesn't really matter so long as you use closures properly. not sure if that's true, but the response was upvoted more than any other. led me to wonder whether the browser overhead of function instantiation is less/greater/similar to function calling.
David Castner
@davidjcastner
Jul 01 2016 15:34
it takes up more memory and yes most linters discourage it. theoretically it will still run your logic properly, but performance with very large inputs is slower
Lily Romano
@Lilyheart
Jul 01 2016 15:40
@lantech19446 you CAN make the program shorter. If it's a one off program that you are going to use for a week and KNOW that you will NEVER need to touch it again, sure. But SHOULD you? Probably not. Someone will hear about the awesome sammich program and want a pasta program. OR the original people decide they want changes, OR you get an email a year later that it's broken even tho they ASSURED you it was going to be used for one week. They stories go on and on
Lily Romano
@Lilyheart
Jul 01 2016 15:46
About the for vs forEach. forEach is faster. A simple compare of the two might not seem like that much of a difference, but if you are looping through a database of many objects with nested array etc and there are many forEach's (there are two just in david's code above), it all adds up to a big difference.
Also remember in JavaScript front end, the browser/webpage "locks up" while running, speed/performance counts.
Lily Romano
@Lilyheart
Jul 01 2016 16:02
It's such a beta world. Get and email -> Your beta invitation is here to XYZ!. I'm like.. um... I kinda remember the name but NO clue what it is.
Lily Romano
@Lilyheart
Jul 01 2016 16:11
git lesson for today, you can --grep git log e.g. git log --grep=Education (case sensitive, usual -i flag for otherwise i.e. git log -i --grep=Education )
(grep is search that can use regex but you don't need to get regex-y on it)
I can see this being useful if you make good git commit commits (beyond just the single line).
Eric Phy
@SimplyPhy
Jul 01 2016 16:49
very nice, very nice
so I'm losing my mind
Lily Romano
@Lilyheart
Jul 01 2016 16:49
"No beer and no TV make Homer something something" "Go Crazy?" "Don't mind if I dooooooooooooo!"
Eric Phy
@SimplyPhy
Jul 01 2016 16:50
I keep re-loading 2 perf test pages, which just create 100k divs in a loop, and push each div into an array; and console.log'ing the array and the container div that contains everything....and the console.log's keep changing!
not everytime, but spuratically
like they'll sometimes log the container's selected node (like with the browser object stuff inside), and other times it'll log the container with the divs inside
it's maddening
not to mention one of the two perf pages sudden began taking like 2.5x longer to load, and i didn't change anthing
Lily Romano
@Lilyheart
Jul 01 2016 16:56
No suggestions there.
Eric Phy
@SimplyPhy
Jul 01 2016 17:02
Why does happy increment here? Shouldn't happier be the only variable that's incrementing?
var happy = 0;
for(var i = 0; i < 100000; i++) {
    console.log(happy);
    var happier = happy++;
}
oh...
happy++ == happy = happy + 1 ...
right...?
yup
wow that's weird
Eric Phy
@SimplyPhy
Jul 01 2016 17:28
Why doesn't s1 = 2?
var happy = 1;
var s1 = happy++;
console.log(s1);
"If the operator appears before the variable, the value is modified before the expression is evaluated. If the operator appears after the variable, the value is modified after the expression is evaluated. In other words, given j = ++k;, the value of j is the original value of k plus one; given j = k++;, the value of j is the original value of k, which is incremented after its value is assigned to j."
sigh
Lily Romano
@Lilyheart
Jul 01 2016 17:51
yeah ++x and x++ are evaluated differently. Many people avoid using ++ all together. The safest way is only EVER keep it on a line by itself. That is most explicit. So happy++ THEN var happier = happy
One of the most important things you can do when learning a new language is read about it's order of precedence.
Sorry, I've been slacking on reading my book so I was sitting on the couch reading and the cat came to sit with me and as you know you are not allowed to move until the cat does.
Eric Phy
@SimplyPhy
Jul 01 2016 18:40
Good news: I understand Function.prototype.call() now :D
Lily Romano
@Lilyheart
Jul 01 2016 18:40
Nice! I know David uses that a bit (I think I know that anyway.. )
Eric Phy
@SimplyPhy
Jul 01 2016 18:42
it's actually reasonably simply; just had to play around with it a bit before it really sunk in
Lily Romano
@Lilyheart
Jul 01 2016 18:42
So much of it is like that!
Lily Romano
@Lilyheart
Jul 01 2016 18:48
seven more pages to read. brb
David Castner
@davidjcastner
Jul 01 2016 19:35
you can think of prototype as defining class methods
var ClassName = function() {
    // initialize class
};

ClassName.prototype.methodName = function () {
    // method code
};

var obj = new ClassName(); // create an object of class ClassName
obj.methodName(); // calling the method
Eric Phy
@SimplyPhy
Jul 01 2016 21:19
w00t
Lily Romano
@Lilyheart
Jul 01 2016 21:19
t00w?
Eric Phy
@SimplyPhy
Jul 01 2016 21:19
never thought of it like that o.o
Lily Romano
@Lilyheart
Jul 01 2016 21:20
MontCode: Shedding new light on new subjects
Eric Phy
@SimplyPhy
Jul 01 2016 21:20
time to get serious about this...cat clicker
SimplyPhy @SimplyPhy smh
Lily Romano
@Lilyheart
Jul 01 2016 22:03
clickitclickitclickit
tfw it’s 6 pm and you have no github contribs
Eric Phy
@SimplyPhy
Jul 01 2016 22:20
No idea what you're talking about. I also have github contribs by 6pm.
Eric Phy
@SimplyPhy
Jul 01 2016 22:26
p.s.
Math.floor(Math.random() * anyNumber); === Math.random() * anyNumber | 0;

// except when anyNumber > 2,000,000,000 || anyNumber < 0 
// (in which case the "Floor" value of anyNumber will be 
// exactly 1 greater than the "| 0" value of anyNumber
w00t
Lily Romano
@Lilyheart
Jul 01 2016 22:33
How many github contribs do you have today again?
Lily Romano
@Lilyheart
Jul 01 2016 22:43
@SimplyPhy is it exactly at 2,000,000,000? 2,147,483,647 would make more sense as that is the rollover to 32 bits.
Eric Phy
@SimplyPhy
Jul 01 2016 22:44
:P
you might be closer to the mark
easier to remember 2bil; for me
Lily Romano
@Lilyheart
Jul 01 2016 22:44
it's a bitwise operater so it's comparing each bit.
Eric Phy
@SimplyPhy
Jul 01 2016 22:44
yup
i just finished reading up on dat
Lily Romano
@Lilyheart
Jul 01 2016 22:45
That's a big diff due! over 147 million!
Eric Phy
@SimplyPhy
Jul 01 2016 22:45
pshh
Lily Romano
@Lilyheart
Jul 01 2016 22:46
If you don't like the exacts in decimal, then say something like except when anyNumber is less than 32 bits long in binary. If you are talking to someone about bitwise, they will know how to figure it out. We programmer have to be exact. If we aren't airplanes crash.
Eric Phy
@SimplyPhy
Jul 01 2016 22:50

here solve this:

if fifty-two is written as 52 in decimal (base-10) notation, as 110100 in decimal (base-2) notation, how do you write fifty-two in hexadecimal notion (base-16) ... NO CHEATING :sparkles:

Lily Romano
@Lilyheart
Jul 01 2016 22:54
Don't give the binary if you want trip someone up in hex. It's easy to get to hex from binary.
110100 = 0011 + 0100 = 3 4
Eric Phy
@SimplyPhy
Jul 01 2016 22:56
and the student becomes the teacher xD
Lily Romano
@Lilyheart
Jul 01 2016 22:58
Did that make sense? 110100 = 11 + 0100 = 0011 + 0100 = 3 *4 = 34 maybe that looks better?
Eric Phy
@SimplyPhy
Jul 01 2016 22:58
i think your first way looked better
Lily Romano
@Lilyheart
Jul 01 2016 22:59
octal is the same way but you split it into three. So 110100 = 110 100 = 6 4
Eric Phy
@SimplyPhy
Jul 01 2016 23:00
I don't know what octal is :'(
Lily Romano
@Lilyheart
Jul 01 2016 23:00
base 8
Eric Phy
@SimplyPhy
Jul 01 2016 23:00
I know what octal is :D
Lily Romano
@Lilyheart
Jul 01 2016 23:08
brb oven mitt
Eric Phy
@SimplyPhy
Jul 01 2016 23:25
Just finished learning about currying with bind() :D
Can you pass in this as the first argument to bind() ?
e.g. someFunction.bind(this, arg1, arg2);
I'm thinking it could potentially have use in automation, though I'm not entirely sure that it's not redundant *I suspect it is xD
Eric Phy
@SimplyPhy
Jul 01 2016 23:54
I believe I found my answer, and interestingly enough, it's yes...though I don't entirely understand the implications of that yet