Knowing something
#1

hello!

I just want to ask what is the difference between these:

if(IsACop(playerid) && PlayerInfo[playerid][pRank] >= 7 || IsSpecial(playerid) || PlayerInfo[playerid][pAdmin] >= 5 && PlayerInfo[playerid][pAdminDuty] == 1 || PlayerInfo[playerid][pHydraR] == 1)

more explanation:

What is the difference between: (||, &&) (==, >=, <=) ?

please help thanks!! (if it is wrong section to ask please pm)
Reply
#2

Basic Pawn?

|| is 'or', && is 'and', == is 'equal to', >= is 'equal or larger than' and <= is 'equal or smaller than'.


Edit: So in English, the line says 'if player is a cop and rank is equal or larger than or player is special or player is admin level equal or larger than 5 and admin is on duty or player is in hydra'.

Edit2:@admantis: Sorry, made a mistake in larger and smaller. :$ And I know they teach it in school, so don't blame me please.
Reply
#3

Quote:
Originally Posted by Basssiiie
Посмотреть сообщение
Basic Pawn?

|| is 'or', && is 'and', == is 'equal to', >= is 'equal or smaller than' and <= is 'equal or larger than'.
>= is 'equal or larger than' and <= is 'equal or smaller than'.
They teach > and < at elementary school, don't you know?
Reply
#4

Thanks Basssiiie!!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)