Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

I get an error message saying that “The left side of = must be a modifiable lvalue” or “error: non-lvalue in assignment”. Whats a modifiable lvalue?

Error Left message modifiable
0
10 Posted

I get an error message saying that “The left side of = must be a modifiable lvalue” or “error: non-lvalue in assignment”. Whats a modifiable lvalue?

0
10

– A value that can be modified and can be on the left of an assignment statement. A statement like “7 = i” (or “i = 7” if “i” is a const) would provoke such a message. Perhaps you have something like “if (7=i)” where you meant to have “if (7==i)”.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123