Wednesday, January 26, 2011

Lilian C's computerless algorithm

//how to define a thief

int pt = 0;//accumulate points to check if a person is a thief
int person;

void setup(){

}

void draw(){
checking();
calculatingPoints();
}

void checking(){
if (person == shifty eyes){ //check if a person has shifty eyes
pt++;
}

if (person == big bags){ //check if a person has big bags
pt++;
}

if (person == sneaky){//check if a person is sneaky
pt++;
}

if (person == afaid){//check if a person is afraid
pt++;
}
if (person == paranoid){//check if a person is paranoid
pt++;
}

if (person == hands are clamy || sweaty){//check if a person is clamy or sweaty
pt++;
}

if (person == nervous){//check if a person is nervous
pt++;
}

if (person == shaky){//check if a person is shaky
pt++;
}
else{
pt += 0;
}
}

void calculatingPoints(){
if (pt < style="color: rgb(255, 102, 0);">else if (pt > = 4 && pt < = 5){ keep and eye on that person; } else {
invesgate that person;
}
}



No comments:

Post a Comment