Julia Community 🟣

Discussion on: Variables, Expressions, and Statements in Julia

Collapse
 
vvpisarev profile image
Vasily Pisarev

I think it would be more correct to say that Julia does not differentiate between statements and expressions, any valid code fragment is an expression (i.e. its evaluation produces a value that can be assigned to a variable, or used in another expression etc.) Those expressions are occasionally evaluated purely for side effects - in case of printing, loop expressions etc. but they still evaluate to some value, which may be nothing.

Collapse
 
ifihan profile image
Ifihanagbara Olusheye

Thanks for this