Mantık programlama yardım

0 Cevap php

A = if infos !empty and inputs empty - do remove;

B = if infos empty and inputs !empty - do add;

C = if infos !empty and inputs !equal to infos - do add;

Biz gibi olabilir:

if B //it's the most common operation, so at the beginning.
{
  //add 
}
else
{
 //remove
}
elseif(c) 
{
 //the same add
} 

Ben bunu daha iyi düşünce olabilir inanıyorum. Yardımına alabilir miyim?

Teşekkür peşin,

0 Cevap