#include<stdio.h> 
int main () 
{ 
char str[100]; 
int n,i,j,c=0,count=0; 
printf ("Enter the String:"); 
scanf ("$s",str); 
printf ("Enter the number of frames:"); 
scanf ("gd",&n); 
int frames [n]; 
printf ("Enter the frames size of the frames:in"); 
for (i=0;i<n;itt) 
{ 
printf ("Frame d:"i); 
scanf ("&d" &frames [i]): 
} 
printf("Frame sd:",i); 
scanf ("&d",&frames[i]); 
} 
printf ("InThe number of frames sd\n",n); 
for (i=0;i<n;itt) 
{ 
printf ("The content of the frame $d:",i); 
j=0; 
while(c<strlen(str) && j<frames[i]) 
{ 
printf("sc",str[c]); 
if(str[c]!="I0") 
{ 
Count ++; 
} 
c=c+1; 
j=j+1; 
} 
printf("InSize of frame &d : &d\n\n",i,count); 
count=0; 
} 
} 
OUTPUT 
Enter the frames size of the frames : 
Frame 0:5 
Frame 1:5 
Frame 2:5 
The number of frames : 
3 
The content of the frame 0:10010 
Size of frame 0 
5 
The content of the frame 1:10101 
Size of frame 1 
5 
The content of the frame 2:01 
Size of frame 2 2