Three states in one line state check? (regarding Java syntax)
===

That the code snippet

	if (addMore) {
		y = x + moreValue;
	} else {
		y = x;
	}

can be compressed into:

    y = (addMore ? x + moreValue : x);

Is familiar to most programmers with a some experience with Java.
But I was wondering if more than two states can be compressed into one line, eg:

    if (addMore) {
    	y = x + moreValue;
    } else if (50 < x) {
    	y = 50;
    } else {
    	y = x;
    }

How can this (if possible that is) be compressed into one statement, something like:

    y = (addMore ? x + moreValue {SOMETHING IN HERE} : x);