{"name":"a : b","operator":":","title":"a : b","type":"command","url":"https://community.bistudio.com/wiki/a_:_b","revid":329506,"updated":"2022-07-29T13:38:09Z","groups":["Program Flow"],"status":"ok","games":{"arma1":"1.00","arma2":"1.00","arma2oa":"1.50","tkoh":"1.00","arma3":"0.50"},"since":"arma1 1.00","arma3_since":"0.50","description":"See switch","syntaxes":[{"syntax":"a : b","params":[{"name":"a","type":"Switch Type","type_expr":"Switch Type"},{"name":"b","type":"Code","type_expr":"Code"}],"returns":{"type":"Nothing","type_expr":"Nothing"},"form":"binary","left":{"text":"a"},"right":{"text":"b"}}],"examples":[{"text":"```sqs\n? (_var == _test) : hint \"_var is equal to _test!\";\n```","code":["? (_var == _test) : hint \"_var is equal to _test!\";"]},{"text":"```sqf\nswitch (_condition) do\n{\n    case 1: { hint \"1\" };\n    case 2: { hint \"2\" };\n    default { hint \"default\" }; // note: NO colon for the default case\n};\n```","code":["switch (_condition) do\n{\n\tcase 1: { hint \"1\" };\n\tcase 2: { hint \"2\" };\n\tdefault { hint \"default\" }; // note: NO colon for the default case\n};"]}],"see_also":["Control Structures","switch"]}