Professional Documents
Culture Documents
Semester VI
Subject Artificial Intelligence
Subject Professor In- Prof. Sachin Deshpande
charge
Assisting Teachers Prof. Sachin Deshpande
Laboratory
Experiment Number 5
Program Code
Department of Computer Exp.5
#include<stdio.h>
#include<string.h>
int i,j,c=0,l,r,u,d,cl=0;
l=r=u=d=0;
while(c<=25)
{
if(board[posr][posc]=='d')
{ printf("CLEAN\n"); cl=1; }
board[posr][posc]='v';
r=1;
d=1;
l=1;
u=1;
if(l==1 )
else if(r==1 )
else if(d==1 )
++c;
cl=0;
int main(void) {
int pos[2], i;
scanf("%d", &pos[0]);
scanf("%d", &pos[1]);
scanf("%s[^\\n]%*c", line);
return 0; }
Department of Computer Exp.5
Output