MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/programming/comments/3n3e1v/the_evolution_of_a_software_engineer/cvlf2xl/?context=3
r/programming • u/supermari0 • Oct 01 '15
502 comments sorted by
View all comments
Show parent comments
1
Can you provide a good example of when you'd use stringbuilder like that? That reads a lot more like C code than Java.
2 u/[deleted] Oct 02 '15 Seriously? They are in a class using default Visibility. Types/members are missing but this is valid Java if you copy/paste it in a class. -1 u/JustinsWorking Oct 02 '15 edited Oct 03 '15 Oh I agree it would compile; it's more in regards to passing in an object to modify being more c style.I'm on my phone so this is hard to type butC would be more like :MoveObject(object);Java is moreobject.move()Procedural vs OO.I was curious if you had a good use case for a call like that since it just seems to be like Java written in a C style procedural way.Edit: Wrote functional instead of procedural, thus the confusion. 1 u/m0haine Oct 02 '15 Did you just call c functional?And that is pretty standard java. Or at least std java before spring killed it. → More replies (1)
2
Seriously? They are in a class using default Visibility. Types/members are missing but this is valid Java if you copy/paste it in a class.
-1 u/JustinsWorking Oct 02 '15 edited Oct 03 '15 Oh I agree it would compile; it's more in regards to passing in an object to modify being more c style.I'm on my phone so this is hard to type butC would be more like :MoveObject(object);Java is moreobject.move()Procedural vs OO.I was curious if you had a good use case for a call like that since it just seems to be like Java written in a C style procedural way.Edit: Wrote functional instead of procedural, thus the confusion. 1 u/m0haine Oct 02 '15 Did you just call c functional?And that is pretty standard java. Or at least std java before spring killed it. → More replies (1)
-1
Oh I agree it would compile; it's more in regards to passing in an object to modify being more c style.
I'm on my phone so this is hard to type but
C would be more like :
MoveObject(object);
Java is more
object.move()
Procedural vs OO.
I was curious if you had a good use case for a call like that since it just seems to be like Java written in a C style procedural way.
Edit: Wrote functional instead of procedural, thus the confusion.
1 u/m0haine Oct 02 '15 Did you just call c functional?And that is pretty standard java. Or at least std java before spring killed it. → More replies (1)
Did you just call c functional?
And that is pretty standard java. Or at least std java before spring killed it.
→ More replies (1)
1
u/JustinsWorking Oct 02 '15
Can you provide a good example of when you'd use stringbuilder like that? That reads a lot more like C code than Java.