« first day (1189 days earlier)      last day (3763 days later) » 

user1596138
5:00 PM
> For half that money, I can get someone to break into their apartment and smash their stereo.
 
for(a in b=(r=readline()).split(''))for(;+b[a];r=b.join('')+'\n'+r)b[a]--;print(r)
 
user1596138
lol
 
function string_check(str, callback) {
	$.ajax({
		type: 'POST',
		dataType: 'text',
		url: '/str_check',
		data: { ticker: str },
		success: function(data) {
			callback(data);
		}
	});
}
string_checker(str, function(data) {
  // work with data
});
@rodling ^^^
use callbacks
 
!!black like your soul or local and organic
 
@RyanKinal black like your soul
 
5:01 PM
Coke?
 
thanks!
 
@rlemon getById and getElementById work just the same?
 
getByID is me being too lazy to write getElementById
 
@OctavianDamiean Coke?
 
@rlemon string_check -> string_checker
 
5:03 PM
@rlemon oh XD, that's why I couldn't google it
 
@RyanKinal Basically, I have no idea what you are talking about.
 
oy vey
 
@OctavianDamiean Coffee
 
@SomeGuy :-) Me and my bud are going to build custom cpu controlled hijackers as a sunday project.. u in ?
he is h/w engineer
 
I was taking a stupid internet quiz, and those choices were mutually exclusive.
Which was unfortunate.
 
5:05 PM
@Shmiddty eh, my bad
!!afk going to get food.. then eat it.
 
is there something like getElementByTag ?
as of document.getElementByTag('textarea')
 
And said stupid internet quiz has decided that my ideal city is Paris.
 
@RyanKinal why do you even do internet quiz XD
 
Funsies
Distraction
 
user1596138
@Cicada3301 ElementS
 
5:07 PM
Because I finished my biggest task for the day
 
user1596138
document.getElementsByTagName('')
 
Because I'm technically on lunch
 
BRO!!! DO YOU EVEN GOOGLE?!?!
 
@Jhawins Sweet!
 
@Jhawins thx!
@rlemon coudn't find it
 
5:08 PM
@Cicada3301 rlemon is afk: going to get food.. then eat it.
 
user1596138
Also, as lemon said, fucking Google! :P
 
@AbhishekHingnikar 1) I don't know how I would contribute. 2) Prelims going on!
 
@CapricaSix got it
 
AH. good luck (y)
 
user1596138
!!google JS getelementbyid for tags
 
5:08 PM
I will give u a simple plugin.. :3
 
generate the horriblest tone u can :D
 
user1596138
^ Stupidest way to do it and I bet it STILL comes up
 
user1596138
Nope.
 
user1596138
Still. "JS get elements by tag"
 
5:09 PM
@Jhawins I looked for it... but I frigging get only italian links (country restriction over our internet), and so nobody is really talking about them
 
user1596138
Ok.
 
user1596138
You can also do things like document.frames[] and document.images[] etc. . .
 
user1596138
images, applets, links, forms and anchors
 
Once again, for the 10th time this week alone.. fuck you IE7. Just fuck you.
 
@rlemon what did you mean by callback a function that send it back? because I am looking to return data rather than call another function
 
5:15 PM
@Jhawins I don't need those for now
 
@rodling rlemon is afk: going to get food.. then eat it.
 
@RUJordan and my life and the italian meaning of grammar
 
@rodling please google callback and read
 
@rodling recursion, I think
 
Typically, if you "think" recursion is the answer, it's not.
 
5:16 PM
@RUJordan awwww... but... my life..
 
In my 4 years developing, I've yet to encounter a situation that required recursion
 
@RUJordan I think none requires... but some are prettier and better performing...
can someone teach caprica to remove all of my ellipsis plz?
 
!!google when is recursion acceptable javascript
 
@RUJordan It's acceptable everywhere
Recursion is fun
 
5:20 PM
I was always taught it's more overhead than it's worth most of the time
 
I think recursion could be quite useful in games that generate graphics
Especially terrain
Or anything that may resemble a fractal
 
wth? I just got a call from a phone receptionist kinda voice saying 'goodbye' and then closing the call
anonimous number
 
@RUJordan Have you looked at sorting algorithms?
Some of them can't be done without recursion
 
user1596138
@Cicada3301 You need to learn. That's why I gave you them.
 
user1596138
When I was 13 I didn't have a phone.
 
user1596138
5:23 PM
I had to get a job at 14 so I could afford one.
 
@Jhawins You worked at the a graveyard once, right?
 
@Jhawins I prefer to learn stuff when I'll need a use for them, so I fully understand what they should do
@Jhawins well... at the time they costed much... I don't have a personal phone either, but just lifestyle choice
 
@SomeGuy I did say "most", not all ;)
 
user1596138
@Cicada3301 That's stupid. You can't say "oh I'll learn it when I need it" because you won't know what it is you need to learn when you need it.
 
We did recursive sorting in Java, it was brutal
 
5:25 PM
@Jhawins That's not right, if he sees his data structures are too slow he can look up some that are faster
 
@Jhawins I can imagine what it does from the name... when I'll use applets I'll know what to look for
 
user1596138
@copy What?
 
ohai @copy
 
Maybe he uses shift and push a lot and then realizes that it's better to use some other structure
@OctavianDamiean Good day to you, sir
 
user1596138
5:27 PM
Sure, some things are learned by experience. Of course.
 
user1596138
I didn't say they weren't.
 
@Jhawins in your cases almost all of them... you told me you learnt all by your own, right?
I call that experience, if you don't take courses
 
user1596138
@Cicada3301 I learnt without formal education. I did NOT learn on my own. For awhile I was just figuring things out as I went, but then I found SO and the things I've learned from this room alone still surprise me. I often already know the solution to something because someone else talked about it or taught me it here, and I wanted to learn from them when they did.
 
user1596138
I learned by experience as well as by example. Both are important.
 
user1596138
And you don't want to strive to be like me haha
 
5:31 PM
I love it when that happens. A while back, I was having an issue with running some code whenever something-or-another happened in a different frame. Because I had been watching/reading this room, I knew about pub/sub and it was easy to implement.
 
@Cicada3301 Did you try any of the problems at Project Euler?
@phenomnomnominal Damn, man, when'd you get so far ahead? 45 solutions?!
 
user1596138
Exactly. That's the kind of thing I mean. I learned from people giving me or someone else more information then they needed, and I decided to research it and learn how to use it regardless of whether or not I had a real use.
 
@SomeGuy I started it, I did some of the fibonacci yesterday, but then needed to sleep
 
user1596138
How many times do we come in and ask questions for hypothetical problems. I do it anyway. Because it's better to learn things proactively.
 
@Jhawins Yeah. Florian and I had a conversation yesterday about scalability and load-balancing. I have very little use for it right now, but it's good to think about.
 
5:34 PM
And often times learning about it is what shows you how it can be useful
 
@Jhawins that's what I usually do, except if I don't even know how to make applets and others and I still need to focus on much more, then I prefer to not investigate
 
user1596138
Plus it often leads to learning about other things as well when you look at learning about 1 problem/function/method.
 
user1596138
@Cicada3301 I think you're confused. document.images will return all the images. document.applets will return all the ___?
 
user1596138
Answer that question and you have completely learned this.
 
@Jhawins applets?
@SomeGuy that thing was simply to get a certain element from the html, but in a non generalized way and preferred not to investigate
 
user1596138
5:36 PM
Yeah, you're definitely 13.
 
@Jhawins the point is I have no idea why I should use it when I can't even build an applet
 
user1596138
omg wtf (worth spelling it out. What. The. Fuck.) is up with that guy
 
@Jhawins I have no idea what an applet is actually, lemme google that
 
user1596138
I have more important things to do
 
Applets are deprecated, that's all you need to know
 
5:39 PM
@Jhawins yeah, probably
@copy deprewhat? I have no idea what english is
 
Then look it up
 
gtranslate translates it to 'deprecato...'
Now i'll have to actually get a dictionary...
 
user1596138
Me talking to client on the phone:
Client "Your website isn't working. This is what's happening blah blah blah..."
Me "What browser are you using? Is it a computer or a mobile device?"
Client "Just Safari"
.... 20 minutes later. I dig into the raw access logs because this makes no sense..
Me "Sir, are you using an iPad?"
Client "Umm yeah?"
Me "Umm.... "
 
You should do more and write less
 
It took 30 minutes to fix the CSS to make this thing IE7 compatible. ugh.
 
user1596138
5:41 PM
Asshole
 
@copy which apparently means insulting... is that right?
 
user1596138
@Cicada3301 Hahaha hold on...
 
-_-
 
user1596138
!!tell cicada3301 define deprecated
 
@cicada3301 It means I aint got time to learn your $5 words
@cicada3301 deprecated Simple past tense and past participle of deprecate.
 
user1596138
5:42 PM
Yeah that was sooooo useful
 
Brilliant
 
user1596138
!!define deprecate
 
!!urban deprecated
 
@Jhawins deprecate To belittle or express disapproval of.
@RyanKinal deprecated Outdated; use strongly discouraged.
 
@Jhawins Well, at least you'll see this shit coming from now on
 
5:42 PM
urban wins!
 
user1596138
@Cicada3301 Basically it means it's old and unsupported now. There is a better way to do it.
 
@Jhawins oooook, thx
 
user1596138
@SomeGuy Yeah. I had to look at the raw access logs, get the client to visit a non-standard page and 404 so I could view his user-agent string, and then realized the problem was actually that we don't allow that from mobile and he just needed to click the incredibly obvious "Back to full version" link.
 
Hahaha
 
It took all that to say "It's unsupported" :P
 
user1596138
5:44 PM
His problem was that he couldn't find a link to something. And he made it sound as if he was on his computer and the links just did not exist. I was so confused.
 
as i am typing ` $("#input_box").val()` is "" until i let go of it or whats the dynamic? It seems to have value when I submit with a button, but trying to get it with` $( "#input_box" ).autocomplete()` while typing, doesnt work.
 
simple question: I have a thing which triggers something if the last letter is something or the last 2 letters are something else or if the last 3 letters are something else... do I HAVE to use an if or is there a switch condition to do so?
 
user1596138
I have a thing that does something if something is something and the last 2 letters are something or if the last 3 are something else. How I do
 
user1596138
@Cicada3301 I hate that message.
 
Well. Apparently our bot-abuse is failing today
1 message moved to Trash can
And I fail at moving messages -_-
 
@Jhawins so?
 
user1596138
@Cicada3301 There are a lot of ways. I'm guessing you don't know about the | and & operators.
 
@Jhawins || and && is what I know
 
user1596138
if (value === check || value1 === check1 || value2 === check2) {do stuff();}
 
user1596138
5:51 PM
Or do different things happen depending on the case?
 
@Jhawins and I knew an if would be possible, but a switch?
 
user1596138
You used a lot of "something"'s so it was confusing. What exactly are you trying to do.
 
user1596138
There's no reason to. There's more than likely a better solution that you would never have thought of, t just depends on what you want to accomplish.
 
yay @OctavianDamiean is back!
 
5:53 PM
@Cicada3301 Doubt you can do that with a switch
 
if something.substring(1,3) do a thing, if something.substring(0,2) do another thing
 
I gave up hope and uninstalled BF3....
 
user1596138
Like, say, you want to change paragraph1's value based on those conditions. You can do something like:
 
user1596138
var res = {abc:'this is what gets replaced if value1 is "abc", efg:'this is for "efg"'};
if (res[val]) p.innerText = res[val]
 
user1596138
How you define val is all that matters then.
 
5:55 PM
@Jhawins no, thank yuo.. @SomeGuy already answered
 
user1596138
You can even use functions in objects.
 
user1596138
@Cicada3301 You're kind of a dick. @SomeGuy just said it was doubtful, he's not sure what you're trying to accomplish either so none of us could be sure. I'm here actually teaching you something useful for the entirety of your coding career (teaching you a method of doing things, not a solution to this problem) and you shoot it down.
 
@Jhawins he actually understood
 
user1596138
Just because you don't understand doesn't mean you don't need to. One day you'll learn this and you'll think "holy shit that's useful in other ways"
 
right @SomeGuy?
 
user1596138
5:57 PM
Ok, I'm done with this kid lol. You guys can have him.
 
Well, not entirely, but I think I figured what you meant
 
@Jhawins I probably will, but for now I'm trying to get a program to work, the theory of other stuff later
and I apreciate your effort @Jhawins
 

« first day (1189 days earlier)      last day (3763 days later) »