help with control structure inside format?
#1

I've seen it used before, but don't know what to call it, so can't find anything when searching. Basically I want an if-else control structure inside a format, like:
Код:
format(string,sizeof(string),"%d",condition(true/false));
Reply
#2

It's called the ternary operator or conditional operator:
PHP код:
condition true false 
Reply
#3

Ah, alright. Thanks alot for the quick reply!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)