Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

write a c program please answer it in the simplest way To check if COVID Social Distancing is applied or not in a classroom, a

write a c program
please answer it in the simplest way image text in transcribed
To check if COVID Social Distancing is applied or not in a classroom, a 2-D array of characters can be used to represent seating in a classroom as in the following example table. The value 'X' in an element of the classroom array means that the seat is not occupied and any other value in an array element means that the seat is occupied. For example consider the following seating table A | n X X 9 1 e K b X X J X E in the above table the element that violate the social distancing rule are H,n,q, 1, e, K, E Write a C function named covid_sd that checks if COVID Social Distancing is applied or not in a classroom. Your function must o accept exactly three parameters named: classroom, num_rows, and ist. The classroom parameter is a 2-D array of characters with 6 columns. This array represents the classroom seating. num_rows is the number of rows in the 2D array, Ist is a 1-D array of characters. The size of Ist is 6* num_rows. o store the values of each seat that violates the COVID Social Distancing rule in the Ist array return 0 if any seat violates the COVID Social Distancing rule and 1 otherwise

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

The Database Factory Active Database For Enterprise Computing

Authors: Schur, Stephen

1st Edition

0471558443, 9780471558446

More Books

Students also viewed these Databases questions