r/programminghorror • • Nov 27 '25

c C—

Post image
531 Upvotes

59 comments sorted by

View all comments

Show parent comment

1

u/GoddammitDontShootMe [ $[ $RANDOM % 6 ] == 0 ] && rm -rf / || echo "You live" Nov 28 '25

Yeah, of course you can have whatever get and set logic you want. Or not even provide a setter and make the property read-only. I was thinking it would also create a private field with the same name of the property for you, but now I'm not sure.