Value NaN of a variable

Thank you very much.

It’s obvious that I have some serious misconceptions, is there any book that explains in comprehensvly processing functioning?