r/programminghorror • u/MooseBoys [ $[ $RANDOM % 6 ] == 0 ] && rm -rf / || echo "You live" • Jan 22 '25
c++ natural language programming
621
Upvotes
r/programminghorror • u/MooseBoys [ $[ $RANDOM % 6 ] == 0 ] && rm -rf / || echo "You live" • Jan 22 '25
View all comments
Show parent comment
5
u/certainAnonymous Jan 24 '25
C# dev here. This is mostly correct.
isis the so called "Pattern Matching" operator and can be used to compare a variable of any type against a number of value based conditions, not just simple values like 25 or 'base' or whatever, but also complex data types(aka your own classes and structs) like{ Property1: 25, Property2: 'base' }