2012-02-03 16 views
16

, bu gibi olacaktır:"Eşit değil" için F # sözdizimi nedir? C kodunda

if (c != 0) { //some code ...} 

neyi F # olacak?

+0

Yinelenen http://stackoverflow.com/questions/239888/logical-negation-operator-in-f-equivalent –

+0

Thx bilgi için üzgünüm –

+3

Bunun bir kopya olduğunu sanmıyorum. O, "!" Diye sormuyor; Bir sayının belirli bir değere eşit olmadığını nasıl test edeceğini soruyor. –

cevap

9

:

match c with 
| 0 ->() //do nothing 
| _ -> ... //do something