Reputation
399
Next privilege 500 Rep.
Access review queues
Badges
4 14
Impact
~17k people reached

  • 0 posts edited
  • 1 helpful flag
  • 29 votes cast
Jan
2
comment In C and C++, what methods can prevent accidental use of the assignment(=) where equivalence(==) is needed?
@underscore_d Edited answer based on your comments. Good point.
Jan
2
revised In C and C++, what methods can prevent accidental use of the assignment(=) where equivalence(==) is needed?
Change based on comments.
Jan
2
comment In C and C++, what methods can prevent accidental use of the assignment(=) where equivalence(==) is needed?
@underscore_d At most of my employers, assignments within a conditional were frowned on. The thinking was it was better to separate the assignment from the conditional. The reason for being clearer, even at the expense of another line of code was the sustaining engineering factor. I worked in places that had large code bases and a lot of maintenance backlogged. I fully understand someone might want to assign a value, and branch on the condition resulting from the assignment. I see it being done more often in Perl, and, if the intent is clear, I'll follow the design pattern of the author.
Nov
3
awarded  Popular Question
Jun
27
awarded  Popular Question
Jan
8
awarded  Notable Question
Sep
24
awarded  Autobiographer
Aug
4
awarded  Curious
Aug
3
accepted Is Lambda Still Supported In Python?
Aug
3
comment Is Lambda Still Supported In Python?
Thanks for the answer and finding the quote.
Aug
3
asked Is Lambda Still Supported In Python?
Aug
1
accepted Notation/Meta Language To Express An Algorithm
Aug
1
comment Notation/Meta Language To Express An Algorithm
Thanks. I'll go look for this. I can express my algorithm using common sense. I know why it works, but not from a more formal standpoint.
Aug
1
comment Notation/Meta Language To Express An Algorithm
Edited OP per this comment.
Aug
1
revised Notation/Meta Language To Express An Algorithm
Add correctness.
Aug
1
comment Notation/Meta Language To Express An Algorithm
Doesn't have to be LC. I'm looking for a meta language to express and then prove the algorithm. I've edited the OP to ask a more general question and leave LC out. Add wording for proving correctness.
Aug
1
asked Notation/Meta Language To Express An Algorithm
Apr
24
awarded  Notable Question
Dec
26
revised What does using (vec col) or (vector arg1 & args) cost?
Fix spelling.
Oct
22
awarded  Popular Question