Implement compare_softmax(scores) for a 1D list of floats. The naive softmax exponentiates directly, , and overflows for large inputs; the stable softmax subtracts the maximum first, .
Return a dict with:
'naive': naive softmax as a list, each value rounded to 6 decimals'stable': stable softmax as a list, each value rounded to 6 decimals'max_abs_diff': maximum absolute difference between the two (unrounded) outputs, rounded to 6 decimalsIf the naive computation overflows (any inf or nan appears), every entry of 'naive' is nan and 'max_abs_diff' is float('nan').