Input and output based execution of mathematica program

Like other programming languages, e.g.-python, in which a program executes the program based of asked input, let’s say I will run a section of program if input is one, otherwise other section of program.

Is it possible to do in mathematica notebook or terminal ?