php/mysql: Chapter20: More decision making with if-elseif-else and boolean operators

Опубликовано: 26 Октябрь 2024
на канале: Armaghan Saqib
26
2

In this chapter, we explore php boolean or logical operators. You can use '&&' or the word 'and' as well as '||' or the word 'or' as logical or boolean operators. There is a minor difference of precedence but if you enclose each condition in brackets, which I always do, you don't need to worry about operators precedence differences.
This is our introduction to boolean operators which is good enough for most purposes. More details and advanced uses of boolean operators (including 'not') will be discussed again in some next chapter.