« first day (1711 days earlier)      last day (3232 days later) » 

3:10 AM
o/
 
 
1 hour later…
4:33 AM
\o
 
morning
 
5:10 AM
@uni working!!!
 
fge
Moo
 
morning everyone!
 
fge
5:25 AM
Hmm, I wonder whether the JIT can perform reordering of conditions
 
5:55 AM
Morning guys
Anyone know why i keep getting NumberFormatException.forInputString(Unknown source) when using this code: while((line = inFile.readLine())!= null){
line = line.trim();
for(int i = 0; i <= line.length(); i++){
x = line.substring(i, line.length() -1);
y = line.substring(line.length()-1, line.length());
sum += Integer.parseInt(x) + Integer.parseInt(y);
}

System.out.println(sum);

}
the file i'm reading consists only of multiple lines of ints
 
Good morning!
 
@Gemtastic morning
 
fge
@UnknownOctopus as long as you don't show the input, no
 
input file contains:
111
222
333
444
 
@UnknownOctopus In the future, please use something like hastebin.com or pastebin.com to post your code
 
6:04 AM
@Gemtastic Ok thx for letting me know
 
fge
And the expected output is...?
 
3
6
9
12
But don't hold me to my code, its 2am here and im tired xD
 
You should learn how to use a debugger
Do you know what a number format exception is?
 
Not the correct type of input
(wrong format of input)
And all i have is jdb for a debugger, but ive ran it and its not helping me much right now
 
fge
final ToIntFunction<String> f = input -> input.chars().map(c -> c - '0').sum();
try (
    final BufferedReader reader = ...;
) {
    reader.lines().mapToInt(f).forEach(System.out::println);
}
DOne :p
 
6:15 AM
@fge Thx
 
@UnknownOctopus are you aware that answer is in Java 8 ?
 
@CrazyNinja Yeah, don't worry man i always stay up to date with the latest versions
 
@UnknownOctopus keep it up !
 
@CrazyNinja :D
 
fge
/javadoc CharSequence#chars()
 
6:23 AM
@fge IntStream chars(): Returns a stream of int zero-extending the char values from this sequence. Any char which maps to a surrogate code point is passed through uninterpreted. (1/2)
 
fge
/javadoc IntStream#map(IntUnaryOperator)
 
@fge IntStream map(IntUnaryOperator mapper): Returns a stream consisting of the results of applying the given function to the elements of this stream. (1/2)
 
fge
/javadoc IntStream#sum()
 
@fge int sum(): Returns the sum of elements in this stream. This is a special case of a reduction and is equivalent to: (1/3)
 
fge
/javadoc BufferedReader#lines()
 
6:24 AM
@fge Stream lines(): Returns a Stream, the elements of which are lines read from this BufferedReader. The Stream is lazily populated, i.e., read only occurs during the terminal stream operation. (1/4)
 
fge
/javadoc Stream#mapToInt()
 
I couldn't find a zero-arg signature for that method. Did you mean this one? (type the number)
1. java.util.stream.Stream#mapToInt(ToIntFunction)
 
fge
1
 
@fge IntStream mapToInt(ToIntFunction mapper): Returns an IntStream consisting of the results of applying the given function to the elements of this stream. (1/2)
 
fge
/javadoc Stream#forEach(Consumer)
 
6:25 AM
@fge void forEach(Consumer action): Performs an action for each element of this stream. (1/3)
 
fge
There you are
This is all the elements that were used in this code sample
 
Ok i saved the transcript to a file, ill take a look at it when i wake up. Thx for all the help guys, im off for now
 
fge
You could do better, of course
 
For my level (Self-taught), this is fine :P
 
fge
<-- also self taught
 
6:29 AM
Nice
 
fge
And in fact the latest element is not Stream#forEach(Consumer) but IntStream#forEach(IntConsumer)
/javadoc IntStream#forEach(IntConsumer)
 
@fge void forEach(IntConsumer action): Performs an action for each element of this stream. (1/3)
 
fge
/javadoc PrintStream#println(int)
 
@fge void println(int x): Prints an integer and then terminate the line. This method behaves as though it invokes #print(int) and then #println().
 
fge
^^^ this is why System.out::println is valid; System.out is a PrintStream
 
6:32 AM
They really need to make the transcript into a plain text doc, it'd be a hell of a lot easier to copy xD
 
fge
SO is not the place for that :p IRC is
And, hmm, let's try that
/javadoc System#out
 
@fge Sorry, I can't find that method. :(
 
fge
Eh
 
Hi :)
 
Morning'
 
6:33 AM
morning
 
hello
 
i am trying to understand event binding mechanism in java, i am coming from javascript background
in javascript it is very easy to bind a callback to a keyword
in java it is different
In javascript , we can save callbacks in Json objects
can it be possible in java?
 
There's absolutely no need for that in Java. JavaScript and Java are very different languages Don't even think in the terms of callbacks because Java doesn't work like that at all
 
@fge Where can i download that IRC you were talking about?
@fge is it created by/for stackoverflow or just programming in general?
 
@Gemtastic agreed , but there has to be equivalent type of functionality.
 
fge
6:38 AM
IRC is the mother of all online chats, and still active today
Defined by RFC 1419 IIRC
It's not a thing you "download", it is something you use
 
I mean download the client
 
fge
Well, depends on your OS
 
@NeiL Well, the whole point with callbacks is to let you know that your asynchronous method is complete, there's no need for that in java, java is synchronous
 
Windows
 
fge
And IRC is the medium of choice for advanced users of a lot of tech communities (JDK devs use it for instance)
Well, a simple <insert favorite online search engine here> search will give you quite a few answers
 
6:41 AM
Ik what IRC is, ive used it before but there are different clients for different things
 
@NeiL It's a bit like asking "How do I turn a screwdriver into a hammer?", the answer is you don't. It's not intended to be used in that manner
 
@Gemtastic hmm.
 
fge
@Gemtastic it's not like Java can't do asynchronous processing
 
@Gemtastic You smack the nail with the screwdriver and hope it works
 
@UnknownOctopus I didn't say you can't try or that it absolutely will never work, but it's not the tool you are looking for ;P
 
6:43 AM
@Gemtastic Suppose , i want to bind a callback on some eventName. And i want to call that event , whenever i want. Can it be possible?
 
@fge It's still an issue of trying to make the tool into another one...
 
@Gemtastic ik ;D you don't always wanna make the mistake of bending that nail
 
@NeiL Java has listeners as the person who answered you explains. These listeners will act whenever what they're listening to will, and you just make it do what you want to happen when it activates.
@UnknownOctopus Or breaking the screwdriver ;P
 
@Gemtastic i could melt down the screwdriver and forge it in a dying star to make a hammer
;D
 
fge
@UnknownOctopus sure, but it's still better to use a hammer in the first place
 
6:46 AM
Really.. No one got the Thor reference...
 
@UnknownOctopus Godmode activated?
@UnknownOctopus Don't speak too soon
 
@Gemtastic backspaces reply
I'm off for the night.. wait its morning.. well anyways im out, peace
 
fge
<-- hopes that JDK 9 will include the possibility to make SAMs out of abstract classes
Right now this doesn't work and it's kind of frustrating: final TreeTraverser<AstNode> traverser = AstNode::getChildren;
 
Morning people!
 
fge
phew Basic Halstead metrics complete
 
7:04 AM
Morning @ita
 
morning all
 
7:48 AM
@uni you worked on table model
 
@Ghanshyam Almost English, try again.
 
@Unihedron ohh tablemodel with java swing
 
Morning
 
hi
 
2 mins ago, by Unihedron
@Ghanshyam Almost English, try again.
Hiya @William
 
7:52 AM
where are you from guys?
 
from here and there...
go stalk some profile pages if you really need to know...
 
haha
 
@Vogel612 what happened with you
 
@William Alpha Centauri.
 
what?
 
7:55 AM
@Ghanshyam ??
 
What you mean what?
 
did you still not got
 
what alpha centauri?
 
Alpha Centauri (α Cen); also known as Rigil Kent (/ˈraɪdʒəl ˈkɛnt/) or Toliman, is the brightest star in the southern constellation of Centaurus and the third brightest star in the night sky. The Alpha Centauri system is located 1.34 parsecs or 4.37 light-years from the Sun, making it the closest star system to our Solar System. Although it appears to the unaided eye as a single object, Alpha Centauri is actually a binary star system (designated Alpha Centauri AB or α Cen AB) whose combined visual magnitude of −0.27 makes it the third brightest star (other than the Sun) seen from Earth after the...
 
@uni i am working on swing if can you tell me please how work tablemodel
 
7:58 AM
@Ghanshyam I wish I could, but that's not something I can turn into speech rationally.
 
you mean you're from alpha
 
6 mins ago, by William
where are you from guys?
I'm sorry, the response to the question would imply where I'm from, right?
 
yeah i understand :)
@Unihedron yeah
 
i mean where do you live
 
me??
 
8:00 AM
@William On Earth. It's also how I have ethernet.
 
:P
 
LOL
 
wew
 
@goodyzain long time
 
Hmmm.
 
8:02 AM
are you guys professionals or students?
 
professional :D
 
nice
 
@William Professional means you're getting paid for things. It's not conflicting with being a student.
 
morning all!
 
yeah
 
8:03 AM
You @William ??
 
i'm just a student
 
just!!
 
Good for you.
 
@William student life is better..
 
@goodyzain working on swing !!
yeah
 
8:04 AM
not really... i'm on a hell year now
 
enjoy moments
 
@William hell year..NO STUDIES...only parties
 
last night play 3d chess
 
playing with one second... x_x
 
8:05 AM
I like too!
 
woah
 
@Ghanshyam you r from ??
 
> IM Aman Hambleton reappears in the chess cave with violent intent
rofl
 
Ahmedabad
@uni LOL
 
@Ghanshyam good
 
8:06 AM
And you thanks
 
Cool, twitch has footage of the international master twitch.tv/chessbrah/b/673910775
 
right now!!
 
no it's not live
 
aha,, I see
@goodyzain are you from !! you visited gujarat
 
Eh, skip to 25 minutes in if you decided to watch the twitch footage and don't care about the commentary.
 
8:12 AM
yupp :)
too long time taking i am at office so, cant see cont....
 
:P
 
how to join?
 
Join what?
 
tournament
 
which one
 
8:14 AM
I don't think you're a professional chess player. They won't let you join any.
 
@uni yeah
 
i'm qualified
 
I already passed you a link, you can register there.
 
@William good
 
yea i have already checked it
 
8:16 AM
here already started ...
 
@William Cool, you have time for a game with me then? I'm bored.
 
sure
 
lol
wait i'm just a noob
 
That's fine.
 
8:20 AM
@Unihedron i'm just joking that i'm qualified...don't take it seriously
 
I don't really care if you're really qualified. I'm not joking about how I'm bored, either. :P
 
It's the small things in life; yaay got upvotes on two different questions! :D
 
LoL he is just student!!
 
LOL
 
I've seen teenagers with 1800 international rating.
 
8:21 AM
@Unihedron GG
 
Teenagers are the only ones with the time to get that score
 
fge
Woohoo
 
and reach top
 
fge
Halstead works!
 
I'm not commenting on that :P
 
8:22 AM
yeah you both give yours view :D
 
@Ghanshyam na i dint..i would like to..:)
 
@fge thumbs up
 
@goodyzain Welcome to GIR watching Lion you know 10 dead on this heavy rain
 
@Ghanshyam Oh oh...
 
yes
 
8:36 AM
You had several checkmating moves back there, but you failed to play any of them. :P
 
@Unihedron GG
haha
well i can't see it
rematch?
 
@William 31... Qf2+ 32. Kh1 Nf4 33. Rc2 Qxc2 34. c7 Qg2#
 
sorry i cant read moves
 
And another you missed at move 32: 32... Qe3+ 33. Kh2 Qf2+ 34. Kh1 Nf4 35. Rc2 Qxc2 36. c7 Qg2#
Algebraic notation (or AN) is a method for recording and describing the moves in a game of chess. It is now standard among all chess organizations and most books, magazines, and newspapers. In English-speaking countries, algebraic notation replaced the parallel method of descriptive notation, which became common in the 19th century and continued with sporadic use as recently as the 1980s or 1990s. European countries, except England, used algebraic notation before the period when descriptive notation was common. Algebraic notation exists in various forms and languages, and is based on a syst...
 
@goodyzain you using skype :)
@uni he missed :D
 
8:40 AM
wanna play again?
 
morning
 
You also missed several around moves 32 to 34:
32... Qe3+ 33. Kh2 Qf2+ 34. Kh1 Nf4 35. Rc2 Qxc2 36. c7 Qg2#
33... Qe3+ 33. Kg4 Qf4+ 35. Kh3 Qf3+ 36. Kh2 Nf4 37. Kg1 Qg2#
34... Nf4+ 35. Kh2 Qg2#
 
ok
 
@William Maybe.
 
last game
 
@Ghanshyam i am in office :P
 
hello
 
Hey, you actually finished the game this time. :P
 
haha
nice game
 
@goodyzain can i give my latter add me :)
 
8:54 AM
Although, considering I had two blunders, I expected it to end sooner. :P
 
@uni good
 
@Ghanshyam Use complete sentences please. Words on their own are incapable of delivering isolated meanings.
3
 
@Unihedron yes I will keep in mind thanks
 
sorry @FastSnail i don't know about FileOtputStream
I'm out
 
8:59 AM
ahh no i just made a firefox addon for change stackoverflow theam
 
sigh there goes the architect arguing with a senior dev. Two days in a row about the same topics. They are running out of colours in the emails...
 
colours?
 
yep. Arguing over email
in-line comments
one of the latest was "in-line comments in magenta"
magenta? are you kidding me?
 
guys do java and c# have the same method or syntax in terms of connecting to database? like sql server management studio?
 
@William no
 
9:06 AM
whats their difference?
 
The only thing that's exactly the same is the SQL query provided you write it in text.
 
ok thanks
 
hello
 
hi
thanks for the link @goodyzain
 
9:10 AM
@goodyzain quoting @Gemtastic: "Teach a man to google and he'll be developing for life. Teach a man to have you google it for him, and you'll be googling for him for the rest of his life."
3
 
:)
 
@Tavo yes men
 
rofl
Gem is very quote-worthy now
 
that was a good one
 
@goodyzain can i give you
 
9:15 AM
is there a shortcut in Intellij to quickly type System.out.println() like there is sysout+CTRL+space in Eclipse? It drives me nuts...
 
@tav sout
 
@Unihedron :P
 
@deadlydragon00 thanks!
you are a life-saver
 
@Tavo alt + j then find sout
 
@Unihedron alt+j?
 
9:17 AM
that's hotbinds right?
 
@Unihedron do you like fps games?
 
@Sword Which ones? I like some but most of them are overhyped and stupid.
 
dunno. I'm kind of new to Intellij, I've used mostly Eclipse
\o/ my code worked on the first try!
 
no way
 
@Unihedron I mean in general. There's one on android I installed yesterday. You might like it as well .. Here is the link
And by overhyped, do you mean cod and battlefield??
 
9:19 AM
@Sword There's no such thing as in general when it comes to games. There are always a majority of crappy games in every genre.
Except those few which I'm not going to name for reasons.
 
@Sword he likes command line games :)
 
@deadlydragon00 I don't.
That's a horrible waste of typing effort.
 
@Sword you working on android too! good
 
@Ghanshyam no..I don't
 
ahh, I see
 
fge
9:24 AM
~sonarqube--
 
^ underflow soon
 
fge
@Unihedron no chance, this is a BigInteger
 
LOL
for which purpose is underflow
 
BigInteger to store how much sonarqube sucks?!
talk about redundancy
 
fge
Where is there any redundancy?
@Ghanshyam try and System.out.println(Integer.MIN_VALUE - 1)
But that is really overflow, now underflow
Underflow is another matter
But that is really overflow, now underflow
 
9:28 AM
!!>MIN_VALUE
 
@Unihedron "ReferenceError: MIN_VALUE is not defined"
 
!!>Number.MIN_VALUE
 
@Unihedron 5e-324
 
!!>Number.MIN_VALUE - 1
 
@Unihedron -1
 
9:28 AM
Oh. :(
 
fge
No chance with JS
 
@fge yeah
 
!!>(-Number.MAX_VALUE) - 1
 
@Unihedron -1.7976931348623157e+308
 
@CapricaSix long time :)
 
9:36 AM
@Ghanshyam ya sure
 
x_x
 
@goodyzain thank add me ghanshyam nakiya
 
fge
~javascript--
@Unihedron unrelated but now it's too late; HTTP/2 implementations are aplenty
 
i've given up already
 
fge
Yeah, I kind of guessed it
You have no perseverance :p
 
9:43 AM
my preserverinstance applies to things I feel I have control over ;)
http/2 impl isn't really a thing I was handling well at that time
 
fge
Sure, but then effort is required for this first step as well
Meh, it's your choice what you do with your brainpower
I just happen to have different choices :p
 
10:21 AM
"Removed fluff" is my favourite edit message when moderating
 
@fge Goddamn Spring
All my coworker did is rename the bean
He did it properly too
I have no idea why it broke.
 
@wonderb0lt Mine is "Silences noise".
 
fge
@MadaraUchiha who is "he"?
 
@fge My co-worker
 
fge
Hmm, so, refreshing problems?
 
10:31 AM
If you want to break things, break them fast and leave no evidence..
 
breaks @ItachiUchiha
 
that hurts..
 
fge
breaks free of his chains
 
@fge Nah, now I'm digging in further
He added a request for a bean, defined the bean in a different XML file, and my project doesn't load this extra XML file (because it's a god context and I don't want it)
 
@fge As long as one of us is chained, none of us are free
 
fge
10:34 AM
@MadaraUchiha not surprised :) And ##java is definitely the place to ask in this case
 
@wonderb0lt chained from matrix
 
@fge I don't need to ask, I know what the problem is
The bean is not found, because it's defined in an XML I don't want to include
The solution is either define the bean elsewhere, or just remove the request for a bean altogether and let Spring handle it magically...
Neither option sounds amazing TBF.
 
Lovely
Spring being spring
 
@deadlydragon00 Huh?
 
fge
Welcome to thou, Spring user; shall thou figure out how to do what you want to do; thou shall receive my sincere prayers
 
10:38 AM
neo
 
@fge I'd like ten prayers virus-free, please
 
fge
Virus? What virus? I use Linux
 
same but clearly you didn't get the joke so I'll walk away in shame quietly
 
@fge Linux is virus free?
 
10:44 AM
@deadlydragon00 Linux doesn't allow you to do stupid things without the user being stupid.
 
fge
@deadlydragon00 sure is; bug free, no (nothing is), but virus free, pretty much so
 
In Windows, I can write a program to hijack other windows, send commands to them, and all you need to do is run it as admin (which I can enable by default)
In Linux, when some lame application asks for a root password, you know something is up.
If you operate from root regularly, you're an stupid and ugly and I hate you.
 
@MadaraUchiha I regularly install software ...
 
@Unihedron Really?
 
am I now stupid and ugly?
 
10:46 AM
@Vogel612 No, as in you use your system as the root user even when you don't really need root access
You don't need to be root to surf, or to work, or to do any other things which aren't "IT level", let's call it.
 
@MadaraUchiha You have a question mark, that makes it a full sentence. :p
 
@Unihedron Nope
Check and mate :D
 
:(
 
Ok switching to Linux for a while :P, it might be a bad choice
 
!!summon 78503
 
10:52 AM
@MadaraUchiha That didn't make much sense. Use the !!/help command to learn more.
 
11:10 AM
!!/\\./help
 
@wonderb0lt That didn't make much sense. Use the !!/help command to learn more.
 
You don't make much sense @CapricaSix with your weird mix of IRC commands.
 
 
1 hour later…
fge
12:32 PM
Weee
Debian fs corruption
 
@fge enjoy the rest of your day week then
 
sed 's/week/month'
 

« first day (1711 days earlier)      last day (3232 days later) »