What would be a simple way other than having many if...else functions and hardcoding the variable names as string. Let say we have 10 variables that may or may not contain some values. I want to be able to return a list of all those variable names that are null.
Instead of doing:
if (x == null) return "x"
for all the variables, is there a better way that I can do this? Looking for javascript/jquery or underscore methods.