This story was about teens/kids in a school, they would hook up to some VR or some other device, and it would show them their future. In the book, one of the cool girls saw the future and she was married to one of the "nerds" I guess you'd call it in the class. She didn't want that, so while she was in the "future" she killed him. When they "returned" from the experience, something had happened to the nerd. However, when the future happened, she was left out in the cold, while she saw him in the safety of a walled city with one of the other classmates, that could have been her, instead she is now out in the dystopian landscape instead of being in the safety of the walled city. It sort of sounds like Oath of Fealty, but isn't that book, it was a short story.