How are duplicate keys in SkyrimPrefs.ini treated?

//ads -- adsterra.com -- native banner
?>
In the Skyrim config files, how are duplicate keys treated? For example if the file contains:
bFloatPointRenderTarget=1
bTreesReceiveShadows=1
## Notice two occurrences of the next value
bShadowsOnGrass=0
bShadowsOnGrass=1
What is the value of bShadowsOnGrass
? I think there are three options:
- The first value is set, then all others ignored.
- The last value is kept, overwriting all earlier values.
- No value (or some default) gets set because of the conflict.
Which is right?
Pictures about "How are duplicate keys in SkyrimPrefs.ini treated?"



VisiData demo 1: find duplicate keys in a single dataset
Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.
Images: PhotoMIX Company, Marta Branco, Lukas, Hitarth Jadhav