Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Make sure to Programm it by PYTHON. Thanks def check_vertical (board, r, c): Doe

ID: 3604429 • Letter: M

Question

Make sure to Programm it by PYTHON. Thanks

def check_vertical (board, r, c): Does a run begin here and extend vertically down? If the location is invalid or a run doesn't start here, return False. If it does, return True. . Assume: board is a valid board, r and c are ints. Note: We aren't checking the entire column; we also don't mind if pieces above also match the run check-vertical([[A'], . check-vertical([[A'], . check-vertical([[A'], [A'], [A'], [A'], [A'], [A'], [A'], [A'], [A'], [A'], [A']], [A']], [A']], , ) 3, 0) -1, -1) True False False #not a full run #invalid location

Explanation / Answer

#include<stdio.h>
#include<string.h>

Void main()
{
char **ppl,**prs,*p;
int num_elements,i,num_pairs,j,*know_count;
printf("How Many People");
scanf("%d",num_elements);
know_count = (int) calloc(num_elements, sizeof(int));  
*ppl = (char*) calloc(num_elements, sizeof(char*));

for ( i = 0; i < num_elements; i++ )
{
ppl[i] = (char*) calloc(10, sizeof(char));  
}
printf("Enter the name of %d People",num_elements);
for(i = 0; i < num_elements; i++)
scanf("%s",ppl[i]);

printf("How Many Pairs");
scanf("%d",num_pairs);
*prs = (char*) calloc(num_pairs, sizeof(char*));

for ( i = 0; i < num_pairs; i++ )
{
prs[i] = (char*) calloc(21, sizeof(char));  
}

printf("Enter Pairs(Names seperated by -)");
for(i = 0; i < num_pairs; i++)
scanf("%s",prs[i]);

for(i=0;i<num_elements;i++)
{
for(j=0;j<num_pairs;j++)
{
p=strstr(prs[j],ppl[i]);
if(p)
{
know_count[i]++;
p=null;
}  
  
}
}
printf("Following is the list of Invitees");
for(i=0;i<num_elements;i++)
{  
if(know_count[i]>5 && ((num_elements-know_count)>5))
printf("%s /n",ppl[i]);  
}
}

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote