帕斯卡如果以及如何使用它 [英] Pascal if and if how to use that
本文介绍了帕斯卡如果以及如何使用它的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
大家好,我需要在这样的代码中设置if语句
Hello guys, i need to set if statement in code like this
if x[i] < 0 and x[i] mod 2 = 0 then
这句话不起作用,我不知道为什么,有人可以帮忙吗?
x [i]必须小于0且x [i]也必须是偶数..?
谢谢!
This statement wont work, and i don''t know why, can someone help?
x[i] must be less then 0 and x[i] must also be even numbers..?
Thanks!
推荐答案
自从我使用Pascal已经很久了,但是......你试过用括号吗?
It''s been a long while since I used Pascal, but...have you tried with brackets?
if ((x[i] < 0) and ((x[i] mod 2) = 0)) then
这篇关于帕斯卡如果以及如何使用它的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文