C#C
C#12mo ago
19 replies
Faker

Expression vs Statement vs Expression statement in programming

Hello guys, I know it's a silly question but what is the difference between a statement, an expression and an expression statement in programming?

From what I understood (please confirm and add to it if required), an expression should always return a value, a statement may or may not return a value (what does this mean? can someone elaborate and give example pls). What about "expression statement"
Was this page helpful?