r/java • • Mar 01 '22

Interview with Senior Java Developer

https://www.youtube.com/watch?v=kdMG40wUCm4
205 Upvotes

36 comments sorted by

20

u/back-in-black Mar 02 '22

Ok this did make me laugh. A favourite line was "I spend my time writing Exception types".

20

u/edmguru Mar 02 '22

my favorite was the first one

Sure I can write you a "hello world"... lets start with the test suite

8

u/socialis-philosophus Mar 02 '22

I've worked professionally (ie. being paid not just learned on the side) to program in Java, Scala, Kotlin, C#, VB, and Python.

I really don't understand the Java hate. Every platform has good and bad.

8

u/edmguru Mar 02 '22

Exactly. Java ain't bad at all.

2

u/Areshian Mar 06 '22

It's safe, portable and maintainable.

1

u/Bozzzieee Mar 02 '22

Apart from being wordy and a little bit old school, it is great.

2

u/tofiffe Mar 03 '22

Wordy makes it easier to read. I used early kotlin versions back at uni, half the code, but it was write once - read never. So much easier to write throwaway code in many other languages. Never had that happen with java

2

u/tvidal Mar 02 '22

I don't think it's about being bad, just odd. People have overused some quirks of the Java language and ecosystem which leaves a lot of room for comedy from those not familiar with them, i guess.

2

u/edmguru Mar 02 '22

I was shocked the word "Enterprise" wasn't used

1

u/Bettigehn Mar 02 '22

He said JavaEE though

20

u/amdelamar Mar 02 '22
  • Are you reading off a teleprompter?

<pauses>… No. 😆

53

u/thisisjustascreename Mar 02 '22

Needs more AbstractSingletonProxyFactoryBean.

9

u/agentoutlier Mar 02 '22

I’m old enough to remember and receive a Java coffee mug…. ironically I didn’t drink coffee at the time (I got addicted later in life).

I think I got the mug at a conference or a Java certification test.

Sadly I through it away. BigDecimal.

7

u/Analyst94 Mar 02 '22

Need to catch everything, it's like baseball lmfao.

17

u/BlueGoliath Mar 02 '22

WTF did I just watch?

16

u/[deleted] Mar 02 '22

The reason for Java is the JVM LOL

4

u/Mysterious-Ant-Bee Mar 02 '22

This made my day. lol

4

u/franzwong Mar 02 '22

He didn't wear a tie.

8

u/agentoutlier Mar 02 '22

To be fair that sweater was kind of awesome. Like some 80s movie Scandinavian assassin vibe.

4

u/macro161 Mar 02 '22

I feel personaly offended, at the time of watching this video i was drinking black coffee and writing exception class

8

u/uh-hum Mar 02 '22

This is hilarious! Can someone explain the BigDecimal joke?

12

u/VincentxH Mar 02 '22

BigDecimal is a datatype often used when accurate decimal arithmetic needs to be performed, like with money.

Using floating point primitives, like double, is a classic mistake. Because it leads to problems of floating point arithmetic inaccuracies.

It's both a standard interview question and common mistake in the wild.

0

u/[deleted] Mar 02 '22

[deleted]

17

u/firsthour Mar 02 '22

raises hand

We use it for money.

6

u/temculpaeu Mar 02 '22

int cents only works if you dont have to deal with fractions of cents, not very common but it can happen

5

u/edubkn Mar 02 '22

Gas stations go brr

5

u/thisisjustascreename Mar 02 '22

Financial securities are very often denominated in fractions of a penny. There are also other currencies than dollars in the world.

3

u/VincentxH Mar 02 '22

Yeah that lovely hack. Leading to problems like this with even an unsigned 32 bit int: https://www.google.com/amp/s/www.wsj.com/amp/articles/berkshire-hathaways-stock-price-is-too-much-for-computers-11620168548

At least use a long these days.

2

u/TenYearsOfLurking Mar 03 '22

that sounds like a good idea at first, ... but that's about it

5

u/jvallet Mar 02 '22

Once I got drop on an interview for writing a solution for they challenge that used doubles instead of BigDecimal. Apperently that is big nono.

7

u/stefanos-ak Mar 02 '22

it wasn't that good... maybe for a couple of times, but not worth half the video :p

I think it's about BigDecimal being overused because of hype and not technical requirements.

3

u/[deleted] Mar 02 '22

Very funny.

All of it is true.

5

u/Persism Mar 02 '22

BigDecimal. BigDecimal. BigDecimal!

1

u/Persism Mar 02 '22

He does a bunch of funny ones. I loved his JavaScript and Perl ones.

1

u/edubkn Mar 02 '22

I wish he came with a nonsense comparison to JS though

1

u/Steeli0 Mar 02 '22

Writing a test suite for a hello world program really got me XD.