« first day (2282 days earlier)      last day (2883 days later) » 

11:00
you'll do it when you know it
user6857832
@Unihedron I should add STRIKE_VALUE field in bowling class, right?
@Hemlata yes, and make it private because it's not used anywhere else and the compiler knows "oh this isn't used anywhere else so let's just optimize it away"
user6857832
It is private.
:thumbsup:
user6857832
11:04
Did I said somethin wrong? lol
:thumbsup::bleeding:
user6857832
I didn't get ya lol
It's the textual representation of an emoji.
:thumbsup: is used for 👍
user6857832
Oh yea lol
user6857832
11:06
I usually don't get textual representation of emoji's.
user6857832
@ItachiUchiha Should I do it right now?
I recommend also creating LastFrame extends Frame for the 10th frame since the logic for it is different.
public void frame() {
    Random rnd = new Random();
    Frame frame = new Frame();
    ...
    frames.add(frame);
}
user6857832
I have to add it 10 times, right?
Nope, loop will do it for you
user6857832
11:11
Frames frame = new Frame();
for (int i = 1; i <= 10; i++) {
frame.add(frame);
}
You need 10 different instances of Frame inside frames
user6857832
What is a Frame?
frame.add(frame) => frames.add(frame)
user6857832
My class name is Frames
user6857832
But It should be Frame lol
11:14
yes
user6857832
Did.
user6857832
Now how should I do it?
user6857832
Like create 10 times instances of Frame?
6 mins ago, by ItachiUchiha
public void frame() {
    Random rnd = new Random();
    Frame frame = new Frame();
    ...
    frames.add(frame);
}
user6857832
What is a frames?
user6857832
Oh yea haha
user6857832
Ok
user6857832
And change it to Frame frame = new Frame?
no, move it into frames()
because that's where you use it
user6857832
11:18
I am confused..
@Hemlata What is the confusion?
user6857832
@ItachiUchiha Should I delete that line and change it to Frame frame = new Frame?
user6857832
@Unihedron What's a frames()? I have frame().
@Hemlata delete that line and add Frame declaration and initialization into the frame method.
@Hemlata Why do you need a Frame reference as a field in Bowling?
user6857832
11:21
@ItachiUchiha To add a frame in a list.
When do you add a frame to the list? Only when the user is in the frame, right?
user6857832
Yes
Move this line as the first line of the frame(). This way, you will add a new frame object into the list.
Otherwise, you will be just overwriting the values in the same frame object
and at the end you can fetch the values only from the last frame
because the rest of the values would be overwritten
user6857832
11:26
@ItachiUchiha how?
This is correct but do you understand why did we ask you to make the change?
user6857832
I jus got that we moved it inside the frame(), So we're creating new instance every time, as it is inside the frame(), So once it is created then It gets deleted. So that way we have new instance every time
user6857832
But I didn't got:
and at the end you can fetch the values only from the last frame
because the rest of the values would be overwritten
user6857832
@ItachiUchiha
Do not execute it on your machine and tell me the output of - hastebin.com/ekuguqijoj.java
user6857832
11:34
Ok.
user6857832
Hem?
The list has 2 Persons, so it will print 2 values
user6857832
Wait no.
user6857832
Hem
user6857832
Her
11:37
Well, yes that is what you expect.
And therefore you wrote similar code for bowling.
user6857832
Yea
Now, execute it in the IDE and check the output
user6857832
Ok
user6857832
It's: her
user6857832
her
11:41
Do you know the reason?
user6857832
Nah
user6857832
Wait.
user6857832
lemme think
user6857832
Nah, idk lol
You are updating the name in the same reference of Person both times and add it to the list.
user6857832
11:43
Oh yea
user6857832
But we already added the values to the list tho.
user6857832
So it shouldn't matter
how does that make it not matter?
List just holds reference to the object. Both the references in your list point to the same Object.
you are adding the value of the same object to the list without copying it.
user6857832
11:46
@Unihedron Like list already contains the value, and we didn't changed it.
@Hemlata You are changing the properties of the value you stored by interacting with the value.
user6857832
Um, yea.
user6857832
I'm not really good with when we put an object inside the list. I only know when we put Integer or anythin like that inside the list.
You should read more java tutorials to get a hold of the basics after @ItachiUchiha walks you through the project, your understanding of basics feel lacking.
user6857832
But I don't get good examples related to like list of objects.
11:49
This is why you read tutorials, because they present and solve examples.
user6857832
@ItachiUchiha Can ya teach me this? Lol. I mean like how do ya work with list which has objects in it.
@Hemlata after he teaches you that (assuming he does) go read more java tutorials.
user6857832
Yeah.
user6857832
Um, ok.
11:54
and if you have any questions, ask.
user6857832
The key point is that Java never provides direct access to the values of objects themselves, in any circumstances

Does that mean like if we've a class Main the we can't access the values (Like fields) inside it without a reference in another class?
... no
user6857832
Then?
12:00
it means exactly what it means: when a java field points to an object, it's a value of reference.
user6857832
Can ya please give me an example?
The reference of the value points to the object, and while the value (of reference) isn't changed, the underlying value it points to can be accessed and changed
if you don't get what that means, read up on variables and objects
user6857832
I'm not gettin' anything :'(
user6857832
Um, ok.
12:04
@Unihedron Have you tried Kotlin?
@ItachiUchiha no idea what that is
"Kotlin is a statically-typed programming language that runs on the Java Virtual Machine and also can be compiled to JavaScript source code."
cool I'll never need it
12:16
^ Those references to references only start to make sense after familiarity with memory pointers really.
Gist of the thing that might be simpler to understand is difference between mutable vs immutable objects, eg: javaranch.com/journal/2003/04/immutable.htm
@unserializable BA DUM TSS

Music Exchange

Share music! No limits
post it there
!!urban BA DUM TSS
@unserializable [ba dum tss](http://ba-dum-tss.urbanup.com/8305412) An onomatopoeic reference to the drum sound effect heard after a punchline has been told (called a percussive sting). "ba dum" is the sound of the snare drum and "tss" the cymbal.

It is often used in a sarcastic manner after a cliched or bad joke has been told.
12:21
I wasn't being sarcastic, I was thoroughly impressed by your fabulous joke
@Unihedron well, its a cliche, because its true
I even choked a bit
WHY WON'T YOU BELIEVE ME
After your glorious convincing, I do :)
user6857832
What If I will do this with an int instead of an int[]?
user6857832
12:30
@ItachiUchiha
user6857832
It should still change the value, right?
user6857832
But it doesn't change the value. It's so confusing..
Nice that you figured answer to this one out on your own.
@unserializable we should mark this date on calendars, what a shocking turn of events
user6857832
Can someone please tell me why it doesn't change the value?
user6857832
12:40
@unserializable
Because it's call-by-value.
And int has value that is passed to the function.
function gives a name (a) to that int value.
user6857832
So what was int[]?
but it completely local to the function.
user6857832
But why it changed the value for int[]?
Because int[] is an array, which is reference to the start of sequence of integers.
user6857832
12:43
Oh yea
This reference is passed by value and other state accessible through the reference can be modified.
int[] is an array and array is an object, not a "java primitive" value
user6857832
So that means it only changes the value if it is call by reference, but it doesn't change the values for call by value, right?
but if one were to do a = new int[] {1,2,3} inside the function, that would not escape into the outer calling scope either.
because in that case, just the array reference inside function scope would be reassigned :)
@Hemlata it is always call by value.
think about it like this
a = test doesn't copy the object, it "passes the keys" to the object
12:46
Just that int value is an integer value, but int[] value is a reference.
if you want details more specific and correct, then read up on them
go to google and type in java objects.
user6857832
Um, ok..
passing the key to the box grants the box and not the box itself.
and everything inside stays where they are.
These concepts actually are not simple to explain clearly :)
@unserializable because they aren't intuitive to someone who doesn't understand programming basics already.
12:50
@Hemlata These are actually complex concepts. Don't feel bad if you don't get them the first time.
that's why I said "read up on them", the more directions you look at it, the clearer the big picture will be
Well, hectic learning can be counterproductive too.
^ Itachi agrees
you know what's the most counterproductive?
not making any progress
Everyone is making progress here :)
13:04
towards death
user6857832
@Unihedron I know you're prob talkin bout me lol..
@Hemlata Do you think you haven't made any progress since I started teaching you about OOP?
user6857832
Idk..
Have a Hersheys and try to answer my question again.
!!hershey
13:09
@Hemlata I'd suggest a great book for sequential processing and actually understanding Java and general OOP is Bruce Eckel's tome called Thinking in Java 4th Edition. It is from 2006 and goes up to Java 5 generics.
fge recommended me Java Concurrency in Practice by Brian Goetz, it's the only programming book I've bought (the rest I have read from the local library or online) and I got way more out of it then I've learned on my own
!!urban fge
@unserializable FGE Full Girlfriend Experience....a more intimate sexual experience with a full service provider where the whole experience is performed in a slower, more comfortable, more romantic setting as with a girlfriend. Not a hurried experience where you feel like you might be on an assembly line type schedule
he's in this room right now
Aha, that fge :P
Otherwise thought that the place where you live has really interesting FGE-s :P
13:18
Does anyone have any idea why the exact same Spring Web WAR file would determine the correct authorization when run from IntelliJ on my windows machine but authorize incorrectly when manually deployed to Tomcat on a Linux machine?
Intimate chat about the concurrency :)
@DRich 1st guess would be that Tomcat server configs are different.
fge knows more about Java than anyone else in the room. It was a treat when he used to hang out in the room.
@unserializable Thanks for the guess
I cannot blame him, he is a father now :)
@ItachiUchiha fge knows more about Java than all of us combined
13:19
@ItachiUchiha FGE indeed :D
Any further thoughts regarding which Tomcat setting to take a look at?
we need to build a statue for him
@Unihedron Believe me. I was about to write it :P
@ItachiUchiha great minds think alike
@DRich since you have acess to both IntelliJ Tomcat and deployment env Tomcat -- compare the configs!
Whatever is different, I recommend to look at :P
13:21
considering that I have little to no experience developing on windows machines, I'm not going to comment
@unserializable Fair enough
Thanks!
@DRich yw!
@Unihedron Linux is so inaccessible
My hosted server is CentOS
@DRich yeah right? it doesn't cost a bloody license and all built versions are released differently for 32-bit and 64-bit
@DRich Are you kidding me?
13:23
it really should be more accessible
@ItachiUchiha No?
Linux are the most accessible OS available
FIGHT FIGHT FIGHT
this is fun to watch
When I say "Accessible" I mean easily picked up by new users
Not in a technical sense
who cares about new users
if you know how to use a computer, then you know how to use a computer
if you can't use a computer, windows won't save you
13:26
@Unihedron as someone new to Linux, I care about new users
but also
I think that's been a big impediment to universal adoption
@DRich If by a new user you mean a user who just fires a PC for browsing Facebook, then of course, Linux is not made for them
@ItachiUchiha Well I do more than use Windows for web browsing and porn
but I find Linux very difficult to navigate
The commands don't make sense, so they're harder to remember
I find windows almost impossible to navigate, LOL
13:28
e.g.
"ifup" and "ifdown"
@ItachiUchiha a year ago I installed Ubuntu for a woman who knows nothing about computers and just browses FB. Have heard no complaints. Autoupdates work and all is fine.
those sound to me like test for whether or not something is available
not commands to bring something up or down
So i'd say for these kinds of users, Linux is very fine.
@unserializable Right- I have a virtual machine running Ubuntu
@Unihedron True. I had to switch to Windows because of unavoidable reasons and I still can't use CMD
13:29
the inconsistent behaviours make zero sense, the stupid disc format makes zero sense, the updates make below zero sense
@DRich so "new users" is just another word for "people who don't understand computers and guess wrongly"?
why would you guess? isn't there a manual command?
man ifup
@Unihedron hold on while I try that
Cool! There is a "man" command
guess what commands there also are?
mv for moving files from A to B
Of course there is ;)
woman?!
because mv stands for move
I'm not even going to give examples, all of it are obvious
13:31
cp for copying files from A to B
ls for list directory structure
@DRich lmao
@DRich omg no grill in tech amirit
@DRich lmao
so
If I connect to a hosted CentOS machine
via SSH
How do I load a local file to a specific directory on the CentOS machine?
what is "local"?
13:34
I mean, I don't need the step by step obviously
@Unihedron Local = the desktop from which I'm connecting to the CentOS vm
but what are the commands that are going to be involved?
@DRich scp filepath [email protected]:filepath
@DRich man put and man get
cool
Alright, I'll start working with those
Thank you gents!
13:39
@DRich you can also use WinSCP for mass-moving files between local and remote host
@unserializable THAT looks like just what I need
4 mins ago, by Unihedron
@DRich scp filepath [email protected]:filepath
that's this
@Unihedron so, scp is Linux command
and WinSCP is a windows enabled version ?
@DRich Yeah, you probably do not have scp command on your host.
@DRich scp is the secure copy protocol. there is software for it, but it is probably not a default linux command.
13:42
WinSCP is just a nice GUI for file operations over SSH protocol
@unserializable Yes! Ty!
@Unihedron Is it a command I can enable do you think?
Or is it more likely to be something the hosting service is going to lock down...
brb
@DRich it's a software.
user6857832
I will ask question in a bit lol.
1 hour ago, by Unihedron
go to google and type in java objects.
13:53
Morning, Java!
@Unihedron mv isn't just for moving.
gm Michael
Hey @Rich
@Michael it's also for renaming, which is exactly moving unless you're using some trash file system on a trash operating system also known as w******
which doesn't rename the file but change the metadata
@Unihedron Language, please.
We don't use the W word in here. xD
!!windows
14:00
@DRich That didn't make much sense. Use the !!/help command to learn more.
awww, I was hoping for a joke
@DRich that's not even our room's bot
it's javascript's
@Unihedron Is the opinion of Windows you guys expressed specific to this room?
@DRich it's specific to sane people.
@Unihedron Sure, so I figured the person who owns Caprica might have been one of those and built something in for !!Windows
14:12
you're overestimating our care for windows.
user6857832
user6857832
@ItachiUchiha
user6857832
Why value didn't changed in second class?
user6857832
Is it bc we're passing the value "Hah!" in it and then assigning it to null. So here the variable "baz" is still the same (baz = "Hah!"), as we jus changed the value (Hah -> null). So it doesn't affect the variable baz and it still points to Hah!?
user6857832
@ItachiUchiha
user6857832
Sorry for ping lol
15:16
@Hemlata if you just did someDog = null in first foo() that would not affect anything either. If Java worked like you seem to expect, you'd also get 'Rowlf' back from the first class, not 'Max'.
Read the Eckel book, cover to cover.
But the particular topic is on pages 63-69
^^ That refers to PDF page numbering, the printed page numbering is 41-47
user6857832
@unserializable So what I said is wrong?
Does any body use Primefaces <p:commandLink> successfully????
what's primeface?
user6857832
Did I said this wrong?
http://chat.stackoverflow.com/transcript/message/35229727#35229727
user6857832
@Unihedron
15:22
primefaces is a UI framework for java EE??
primefaces is a UI framework for java ee.
@Hemlata Maybe if it uses english in a way I can read, I would know.
@Unihedron primefaces is a UI framework for Java EE.
@Hemlata Yes it is wrong, you are not passing value "Hah!", you are passing reference to value "Hah!".
user6857832
@Unihedron You mean what I wrote is not a proper english?
@Hemlata not at all
I'm too stupid to understand it
user6857832
15:25
@Unihedron Alright.
Does any body use Primefaces <p:commandLink> successfully????
@ArgaPK with 100% certainty I can tell you that I have never used that <p:commandLink> successfully, nor do I know anyone who has used it successfully :)
user6857832
@unserializable Then why it didn't changed the value?
:-(
user6857832
Cuz it is changing the value in first class, then why it is not changing the value in second class? Though they both are doing the same thing, aren't they? @unserializable
15:27
@Hemlata I have made an attempt to answer that previously. Read the book.
user6857832
Ok.
 
2 hours later…
user6857832
17:22
https://hastebin.com/ruvifigija.cs
What does a = b in the code mean?
user6857832
Line 36
user6857832
@unserializable
may i help you in somethiing ??
@Hem
@Hemlata may i help you in somethiing ??
user6857832
Sure, that would be appreciated.
ok
tell me
what van i help you?
what can i help you?
user6857832
17:33
Do ya know what does a = b mean in the code?
user6857832
In line 36
user6857832
I know it is assigning a = b, but why didn't the value changed outside the method?
user6857832
@ArgaPK
@Hemlata this is simple
user6857832
17:38
Yea?
because you are not assigning values
user6857832
How?
user6857832
Aren't we assigning a = b?
we are not assigning a=b;
user6857832
Then?
17:40
we just making a's refrence same as b's refrence
user6857832
I didn't get.
@Hemlata A reference is what is used to describe the pointer to the memory location where the Object resides. in our case it is a and b;
user6857832
That means a contains the address of it?
user6857832
And we're assigning address of a to b?
user6857832
@ArgaPK
17:48
@Hemlata "but why didn't the value changed outside the method?" the value is not changed because you are modifying pointer before printing the value,
yes , we are assiging address of a to b
Is every entry in a hashmap a linked list even if there is no collision?
user6857832
But if we're assigning the address of it then the value should change.
user6857832
@ArgaPK
user6857832
Well, nvm I'm jus a noob, I can't get anything. Anyway thanks for your help.
@Hemlata hastebin.com/qipohewiwo.cs see this code and run this code , you will surely understand
17:52
@NullPointer what?
@Hemlata Of course ou are assigning a=b. The value of function-scoped reference a will be the same as function scoped reference b. But that does not make any difference to variables outside function (variable test). Because the initial value of a was reference to test, but you yourself made a to refer to b.
Hashmaps store their values in buckets.
@Hemlata value and address of a is changing when we are assiging a=b
@Michael Yes they store in buckets which is based on hasshing. But what if two keys have the same hash? then its stored as a linked list
hashmap stores value as key,value pair
17:54
@NullPointer Java STD lib could be mature enough that there is no chain linked list until collusion. But what Map implementation are you using? Check out its source code.
My questiion was if its store as a linked list even if there is no collision aka same hash for a different key
But java.util.Map is just an interface. Look into concrete implementation you are using, to know for sure.
I was refering to hashmap
From Oracle JDK 1.8 (u 111) java.util.HashMap comments:
` /*
* Implementation notes.
*
* This map usually acts as a binned (bucketed) hash table, but
* when bins get too large, they are transformed into bins of
* TreeNodes, each structured similarly to those in
* java.util.TreeMap. Most methods try to use normal bins, but
* relay to TreeNode methods when applicable (simply by checking
* instanceof a node). Bins of TreeNodes may be traversed and
* used like any others, but additionally support faster lookup
* when overpopulated. However, since the vast majority of bins in
Ok i think i figured the answer. Thanks guys
18:05
Fantastic! You're at least 3rd person here today who has come in and figured something out :)
Well Done
@unserializable considering the huge transcript filled today, that's not very efficient is it
@Unihedron It's not too bad either. As for transcript size, the honourable PDF tome I linked for Hemlata has 1079 pages :)
@unserializable only 1079 pages?
18:12
And not many people come here, TBH,
where are 1079 pages??
@unserializable nice! that's shorter than I'd expect
@unserializable where are these 1079 pages??
here's me regretting my life decisions of not learning by primarily reading books but instead grabbing the freaking wrench
This SO chat is not very active... 55 users currently in 33 rooms.
18:14
@unserializable it's more active than THE TAVERN

The SO Tavern (Free Snacks)

Room 5 was frozen for inactivity even though it was once an ac...
so yeah it is
18:59
@unserializable ok, Thinking in java is one of te
thinking in java is one of the best book for java

« first day (2282 days earlier)      last day (2883 days later) »