✌️_ A machine took 200 sec to sort 200 names, using bubble sort. in 800 sec, it can approximately sort ?_✌️
________________________
❥Nᴏ Cᴏᴘʏ Pᴀsᴛᴇ..!❤️⭐
❥Dᴏ Nᴏᴛ Sᴘᴀᴍ..!❤️⭐ _________________________
ONLY ANSWER MY FOLLOWING ♥️
Answers
▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬
For sorting 200 names bubble sort makes 200 * 199/2 = 19900 comparisons. So,the time needed for 1 comparison is 200 sec approx.In 800 sec it can make 80,000 comparisons.We have to find n, such that n(n-1)/2=80,000. solving n is approx 400.
200 sec for 200 records
200 <= c * [200]^2
c = 1/200
in 800 sec, records, n = ?
800 <= [1/200]*[n]^2
n = 400
▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬
In 800 sec, machine can approximately sort 400 names.
Given,
A machine took 200 sec to sort 200 names, using bubble sort.
To find,
In 800 sec, it can approximately sort ?
Solution,
For sorting 200 names bubble sort makes 200 199/2 = 19900 comparisons.So,the time needed for 1 comparison is 200 sec approx. In 800 sec it can make 80,000 comparisons. We have to find n, such that n(n-1)/2 = 80,000. solving n is approx 400.
* 200 sec for 200 records
200 sec for 200 records200 <= c * [200]^2
200 sec for 200 records200 <= c * [200]^2c = 1/200
200 sec for 200 records200 <= c * [200]^2c = 1/200in 800 sec, records, n = ?
200 sec for 200 records200 <= c * [200]^2c = 1/200in 800 sec, records, n = ?800 <= [1/200]*[n]^2
200 sec for 200 records200 <= c * [200]^2c = 1/200in 800 sec, records, n = ?800 <= [1/200]*[n]^2n = 400
#SPJ3