-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsampletestingcovid19.cpp
More file actions
24 lines (24 loc) · 1.04 KB
/
sampletestingcovid19.cpp
File metadata and controls
24 lines (24 loc) · 1.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#include <iostream>
using namespace std;
int main()
{
int samplestobetested,numofbatches,samplesperbatch,positivityrate;
cout<<"Enter The no. of samples to be tested = ";
cin>>samplestobetested;
cout<<"\nSo the no. of samples to be tested = "<<samplestobetested;
cout<<"\n\nHow many samples are to divided per batch = ";
cin>>samplesperbatch;
cout<<"\nSo the no. of samples per batch are "<<samplesperbatch;
numofbatches=samplestobetested/samplesperbatch;
cout<<"\n\nNo. of batches are "<<numofbatches;
cout<<"\n\nEnter the Postivity Rate = ";
cin>>positivityrate;
cout<<"\nSo the Postivity Rate is "<<positivityrate<<"%";
int numofsamplestoberetested;
numofsamplestoberetested=((samplestobetested*positivityrate)/100)*samplesperbatch;
cout<<"\n\nThe No. of samples to be Re-tested are "<<numofsamplestoberetested;
int totalnumoftestperformed;
totalnumoftestperformed=1+numofbatches+numofsamplestoberetested;
cout<<"\n\nTotal no. of test done are "<<totalnumoftestperformed;
return 0;
}