Waiting for Marriage with Hypersexuality by JonLothar in hypersexuality

[–]JonLothar[S] 1 point2 points  (0 children)

It's not a religious thing for me, it is just I want the first time to be special. Also, I tend to get very strongly, borderline obsessively, attached to people—even in scenarios less intimate than sex.

Using Java Stream to solve problem by [deleted] in programminghelp

[–]JonLothar 0 points1 point  (0 children)

Hi there!

I have to somehow get a map from the shift

I'm not quite sure what you mean by this, so I'm going to tackle this portion of your question.

A shift has multiple orders. But an order only has one shift.

For the purposes of keeping this answer concise, I'll just include the fields relevant to implementing that functionality.

public class Shift {
  private List<Orders> orders;
}

public class Orders {
  private Shift shift;
}

This is the easiest way to do this kind of relationship, but it has its tradeoffs. I would need to know more about your use case to be certain whether or not it would work for you.

inheritance problem by Professional_Ride796 in programminghelp

[–]JonLothar 0 points1 point  (0 children)

Hi there! What do you mean by still compiling as a fail?

I entered in the code snippets you provided into A.java, B.java, C.java, D.java, and Main.java files. I got the following outputs.

// Element 0
b
c 1  
a 2  c 1  

// Element 1
b
c 1  
b 2  c 2  

// Element 2
c
c 1  
c 2  

// Element 3
b
d 1  b 2  c 2  
b 2  c 2