* if-else-if for a single action or block of actions

	program ifthen

	integer x, y, z

	read*, x, y

	if (x.lt.y) then
		z = x + y
	else
		z = x - y

	end if
	print*, z

	if (z.eq.1) then
		print*, 'your z is: ', z
	else if (z.eq.2) then
		print*, 'your z is: ', z
	else if (z. eq.3) then
		print*, 'your z is: ', z
	else
		print*, 'your z is invalid'
	end if

	end
