Programming Fundamentals

·

1 min read

Expression Vs Statement

Expression returns a new value. on the other hand, the statement doesn't return. the statement is just a standalone and doesn't return anything. Expression is a combination of values and functions. that are combined and interpreted by the compiler to create a new value.

Express is a legal combination of symbols that represents a value. for example, 2.9, a+5, 3+7, 3/8, etc. A Statement is a programming instruction that does something e.g some action takes place, print("Hello world");

image.png