# Write an expression that evaluates to true if the integer variable x contains an even value , and false if it contains an odd value .

2

### CHALLENGE:

Write an expression  that evaluates  to true  if the integer  variable  x contains an even value , and false  if it contains an odd value.

### SOLUTION:

```
(x % 2 == 0)

```

• Gregory says:
• Kevin says:
{"ft_lang_label":"__label__en","ft_lang_prob":0.87563616,"math_prob":0.97731084,"size":1318,"snap":"2021-43-2021-49","text_gpt3_token_len":341,"char_repetition_ratio":0.11491629,"word_repetition_ratio":0.1981982,"special_character_ratio":0.23444612,"punctuation_ratio":0.11278196,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.96135366,"pos_list":[0,1,2,3,4],"im_url_duplicate_count":[null,null,null,null,null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2021-10-15T19:45:22Z\",\"WARC-Record-ID\":\"<urn:uuid:f6cec8fd-8525-49b5-8df4-7cf94d7ab6c1>\",\"Content-Length\":\"67233\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:3f1908af-3115-43c8-b2c6-0d58972113bc>\",\"WARC-Concurrent-To\":\"<urn:uuid:5fdb1b55-6703-4561-8119-0e4802ca212d>\",\"WARC-IP-Address\":\"172.67.153.157\",\"WARC-Target-URI\":\"https://matthew.maennche.com/2013/12/write-an-expression-that-evaluates-to-true-if-the-integer-variable-x-contains-an-even-value-and-false-if-it-contains-an-odd-value/\",\"WARC-Payload-Digest\":\"sha1:XTDUR57S2Y6JB22FKVMYN25KBIVCJHKL\",\"WARC-Block-Digest\":\"sha1:K5AN3CCCDFG3RUQY5BPWJG5HWGQG7Y2Z\",\"WARC-Identified-Payload-Type\":\"text/html\",\"warc_filename\":\"/cc_download/warc_2021/CC-MAIN-2021-43/CC-MAIN-2021-43_segments_1634323583083.92_warc_CC-MAIN-20211015192439-20211015222439-00035.warc.gz\"}"}