[swift] Get day of week using NSDate

The practical solution ...

Be aware that results are the integers one through seven.

(Not zero through six.)

let trivialDayStringsORDINAL = ["", "SUN","MON","TUE","WED","THU","FRI","SAT"]
// note that zero is not used

and then ...

let dow = Calendar.current.component(.weekday, from: someDate)
print( trivialDayStringsORDINAL[dow] )