Is it possible to store a NaN in a property list file. I tried:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<array>
<integer>nan</integer>
</array>
</plist>
But Xcode was not able to phrase the file. Any thoughts?
Floats or doubles can be
NaNs, but an integer can not.Also not sure if you can store it in a plist file.
However, if you use
NSUIntegerfor your integer, you can use a predefined marker likeNSNotFound, or you can define your own value that you want to reserve for the purpose.