Strings

A few people are at a party. As they are bored, they decide to connect each other with strings. Every person must be connected to every other person. For example, if there are 3 3 people ( A , B , C ) (A, B, C) , ( A ) (A) will be connected to ( B , C ) (B,C) , ( B ) (B) will be connected to ( A , C ) (A,C) and ( C ) (C) will be connected to ( A , B ) (A,B) . If they have less than 1000 1000 strings, what is the maximum number of people at the party?


The answer is 45.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

22 solutions

Prasun Biswas
Feb 17, 2014

Let the number of people be n n and since every 2 2 people out of n n people should be connected by a string, so the number of strings that would be used is the value equal to the binomial coefficient ( n 2 ) \binom{n}{2} or n C 2 nC2 . According to the problem we have ---

( n 2 ) < 1000 \binom{n}{2} \lt 1000

n ( n 1 ) 2 < 1000 n ( n 1 ) < 2000 n 2 n < 2000 n 2 n 2000 < 0 \implies \frac{n(n-1)}{2} \lt 1000 \implies n(n-1) \lt 2000 \implies n^2-n \lt 2000 \implies n^2-n-2000 \lt 0

Let us now assume that n 2 n 2000 = 0 n^2-n-2000=0 and solve it using the quadratic formula n = b ± b 2 4 a c 2 a n=\frac{-b \pm \sqrt{b^2-4ac}}{2a} with a = 1 , b = ( 1 ) , c = ( 2000 ) a=1,b=(-1),c=(-2000) for this equation. Then, we get ---

n = 1 ± 1 4.1. ( 2000 ) 2 × 1 = 1 ± 1 + 8000 2 = 1 ± 8001 2 n=\frac{1 \pm \sqrt{1-4.1.(-2000)}}{2\times 1} = \frac{1 \pm \sqrt{1+8000}}{2} =\frac{1 \pm \sqrt{8001}}{2}

Since, n n cannot be (-ve), we take the value as n = 1 ± 8001 2 = 1 + 89.45 2 = 90.45 2 = 45.225 n=\frac{1 \pm \sqrt{8001}}{2}=\frac{1+89.45}{2}=\frac{90.45}{2}=\boxed{45.225}

Since, we took the assumption that n 2 n 1000 = 0 n^2-n-1000=0 while actually we have n 2 n 1000 < 0 n^2-n-1000 \lt 0 , so we get n < 45.225 n \lt 45.225

The value less than 45.225 45.225 and still the max value of n n possible is 45 45 , so answer is = 45 =\boxed{45}

But according to the given scenario, if A is connected to B , then B is again connected to A (as their connection has been mentioned twice) So the no of strings for 'n' people should be nC2 x 2 which in this case will give n = 32

Rushil Singh - 7 years, 3 months ago

Log in to reply

You are mistaken. Suppose A and B are 2 people connected by a string. The connection between A and B and vice-versa is done by the same string, not 2 strings . So, the answer will be n C 2 nC2 and not 2 × n C 2 2\times nC2 .

Prasun Biswas - 7 years, 3 months ago

Log in to reply

i didnt have maths so can you tell me what is nC2 is.Is it the same as combination and is n(n-1)/2 the formula for a coefficient..How do we know that were using this formula?

Aishani Yadav - 7 years, 3 months ago

Log in to reply

@Aishani Yadav Actually, n C 2 nC2 or ( n 2 ) \binom{n}{2} is the binomial coefficient which is used to signify the number of combinations or selections possible for n n objects taken 2 2 at a time.

n C r = ( n r ) = n ! r ! × ( n r ) ! nCr=\binom{n}{r}=\frac{n!}{r!\times (n-r)!}

n C 2 = ( n 2 ) = n ! 2 ! × ( n 2 ) ! = n ( n 1 ) 2 nC2=\binom{n}{2}=\frac{n!}{2!\times (n-2)!}=\frac{n(n-1)}{2}

Prasun Biswas - 7 years, 3 months ago

Sorry for the mistake in the second last and the last line, it should be n < 45.225 n \lt 45.225 and the value less than 45.225 and still the max. value of n n possible is 45 45 , so 45 45 is our answer.

P.S. -- The mistake in the last line has been corrected in the solution.

Prasun Biswas - 7 years, 3 months ago

Log in to reply

okk

dheeraj jain - 7 years, 3 months ago

it look like complete graph and in complete graph no of edges n(n-1)/2 so easily compute

Pavan Tiwari - 7 years, 2 months ago

Log in to reply

What graph and what edges ?? For n 2 n 2000 = 0 n^2-n-2000=0 , there is only one solution of n n which is 45.225 45.225 .

Would you explain which graph you are talking about ??

Prasun Biswas - 7 years, 2 months ago

Sir, I solved it using the formula n n + Number of diagonals in a n n -gon. Is it right to do so or was it just luck?

@David Vreken , @Chew-Seong Cheong, @Stef Smith

Vinayak Srivastava - 1 year ago

Log in to reply

It is the same formula.

Chew-Seong Cheong - 1 year ago

Log in to reply

OK. Thanks, Sir!

Vinayak Srivastava - 1 year ago
Venture Hi
Feb 8, 2014

use this formula (x(x-1))/2 < 1000 where x= number of people and (x-1)= number of strings per person. Dividing by two beacause strings from person A to person B is the same as Peron B to A.

Actually the problem can best be interpreted and understood through the concept of combinations. If n n is the total number of people, then we know that a string can connect only 2 2 people and connection from one to another is the same as the reverse, so we use combination not permutation and the answer would be the max value of n n which satisfies the equation n C 2 < 1000 nC2<1000 , i.e., ( n 2 ) < 1000 \binom{n}{2}<1000 .

n C 2 nC2 or ( n 2 ) \binom{n}{2} represents the number of ways to select 2 2 people at a time out of a total of n n people.

Prasun Biswas - 7 years, 3 months ago

apply AP to that u will no it urself

Hrishikesh Dani - 7 years, 3 months ago

x(x+1)/2 is ultimately same as x(x-1)/2. the fact is what you take as answer(x+1 in the first and x in the 2nd i think)

Md Jahirul Islam - 7 years, 3 months ago

yes , i do not think about the same string tied a & b. it is to be devide 2

Suresh Thakore - 7 years, 3 months ago

why am i here

JiYoung Bang - 7 years, 3 months ago

its X(X+1) and not X(X-1)

Hrishikesh Dani - 7 years, 3 months ago

Log in to reply

Why is it (X+1)?

Shashank Rammoorthy - 7 years, 3 months ago
Pushpak Roy
Feb 17, 2014

Simply observing the pattern we can see that if there are n people then starting from the first person , the first person connects with (n - 1) people , the second person connects with (n - 2) people and so on till the last one connects with 1 people . So adding for n people we get (n - 1) + (n - 2) + (n - 3) + ....... + 2 +1 = (n - 1)(n )/2 Now for n = 45 we get the maximum value less than 1000 i.e. 990.

the correct ans is 44 and certainly not 45!....... its the 44 th term in the sequence that yields 22*45......and not 45th term......... if there were 45 guests then there would have been more than a thousand threads!

Mayankk Bhagat - 7 years, 2 months ago

for n+1 number of guests, the number of strings are 1+2+3+4+... ... ... +n .

Assume n(n-1)/2 = 1000 so n = 44 (approx... but we take the integer value)

So the number of guests are 44+1=45

x(x-1)/2 is the right formula instead of x(x+1)/2

Shailendra Bisht - 7 years, 3 months ago
Katherine Steiner
Feb 19, 2014

For there to be the maximum number of people n , each string must connect a different pair. If there were 3 people, there would be 3 strings, for 4 people there would be 6, for 5 there would be 10, and for 6 there would be 15. Note that the number of strings is the ( n -1)th triangle number. The highest triangle number that is still under 1000 is 990, which is the 44th triangle number. Therefore the number of people is 45.

*Triangle numbers are numbers that can be written out as that number of dots in rows to make an equilateral triangle.

Nilesh Sah
Feb 17, 2014

Here the no. of string refers to the no. of pairs that one can form from the given number of people . Here the order does not matter since A being attached to B is equivalent to B being attached to A, hence it becomes a problem of combination and not permutation. The answer is as simple as " nC2 < 1000 " where n should be an integer, which comes at n = 45.

Finn Hulse
Feb 8, 2014

When people are connected, let n be the amount of people. Then the amount of connections is n(n+1)/2. We can set up an equation with 1,000 on the other side, and solve. We find that 45 is the smallest n that fits.

Mahdi Raza
May 24, 2020

Imagine the people as the vertex of a polygon, and the strings as diagonals. The total number of strings would be:

n ( n 3 ) 2 + n < 1000 \dfrac{n(n-3)}{2} + n < 1000 n 2 3 n + 2 n 2000 < 0 n^2 - 3n + 2n - 2000<0 44.2 < n < 45.2 -44.2 < n < 45.2 n = 45 \boxed{n = 45}

Chew-Seong Cheong
May 23, 2020

It takes every two persons to be connected by a string. Therefore n n persons, it is ( n 2 ) \dbinom n2 . To find ( n 2 ) < 1000 \dbinom n2 < 1000 , we have n ( n 1 ) 2 < 1000 n = 2000 = 45 \dfrac {n(n-1)}2 < 1000 \implies n = \left \lceil \sqrt {2000} \right \rceil = \boxed{45} , where \lceil \cdot \rceil denotes the ceiling function .

Stef Smith
May 23, 2020

Nice problem. I won't add another solution as there are plenty here but I really enjoyed taking a pen and paper approach to solving it.

Ahmed Obaiedallah
Jul 18, 2015

Let's say the guests number will be n g \large n_g and the max strings number n s \large n_s

we know logically that each two connected together with only one string

so if we start with one of the guests we will get 2 facts\info

1- n s = n g 1 \large n_s=n_g-1

2-The n s \large n_s will be decreased by "1" with each guest we use as a pivot to create new pairs

n s ) t o t a l = 1 + 2 + 3 + 5 + . . . . + n s \large n_s)_{total}=1+2+3+5+.... +n_s

using the formula

S u m o f n u m b e r s f r o m 1 t o n = n 2 × ( n + 1 ) \large Sum\space of\space numbers\space from\space 1\space to\space n=\frac{n}{2}\times(n+1)

n s 2 × ( n s + 1 ) < 1000 \large \frac{n_s}{2}\times (n_s+1)<1000

you can solve the equation or just try a few numbers between 40 and 50

you'll find out 44 is max number of strings and as follows 45 is the max number of guests

Datu Oen
Mar 27, 2014

Since each of the people are connected then there will be a total of n C 2 _n C_2 number of ways of doing this. Since there are only 1000 stirngs then we look for the largest value of n n such that n C 2 < 1000 _n C_2 < 1000 . By formula, n C 2 = n ! 2 ! ( n 2 ) ! = n ( n 1 ) 2 < 1000 _n C_2 = \frac{n!}{2!(n-2)!}=\frac{n(n-1)}{2} < 1000 . Multiplying both by 2, we have n ( n 1 ) < 2000 n(n-1) < 2000

We assume to have equality. that is, n ( n 1 ) = 2000 n (n-1) = 2000 .
To find the value of n n , we look at the geometric mean of n n and n 1 n-1 which is 2000 = 44.7 \sqrt{2000} = 44.7 .

This means that the integers n n and n 1 n-1 are integers above and below 44.7. Thus we have n = 45 n = 45 .

We can check that 45 × 44 = 1980 < 2000 45 \times 44 = 1980 < 2000 . If we go higher, that is n = 46 n = 46 we can see that 46 × 45 = 2070 > 2000 46\times 45 = 2070 > 2000 .

Bilal Akmal
Mar 27, 2014

A very simple equation can be used.(n-1)+(n-2)+(n-3)+(n-4)+...+(n-n)=strings where n=number of people. If we know the number of strings we can solve the number of people or vice versa. Hope people like it.

Krisna Attayendra
Mar 20, 2014

i solved by thought on using formula how many diagonal in n-gon + n (connect the people outside (as like the side of n-gon)) < strings -> i mean this \frac {n(n-3)}{2} + n < 1000 and i actually i got 45 as my answer.. is it my true or actually i did mistake (means i only got lucky for solving this)??

Bhavesh Bhagde
Mar 16, 2014

n(n+1)/2 where n=44 is equl to 990 strings, 45 people are presnt

Vitor Pacela
Mar 9, 2014

Let's pretend there are N people at the play. Then, the person A will be tied to N-1 people, using N-1 strings. The person B will be tied to N-2 people, using N-2 strings. The person C will be tied to N-3 people, using N-2 strings etc, till the Nth people will be tied to N-N people. The total of strings is

(N-1) + (N-2) + (N-3) + ... + (N-N).

Which could be written as

(N+N+N+...+N) - (1+2+3+...+N).

And knowing that (N+N+N+...+N) has N numbers N, we may say that

(N+N+N+...+N) - (1+2+3+...+N) = N² - [N(N+1)/2] = (N² - N)/2,

that needs to be less than 1000 strings.

(N²-N)/2 < 1000

N²-N-2000<0

Resulting in -45 < N < 46. Therefore, there are a maximum of 45 people.

Vaishnavi G
Mar 9, 2014

Let the total number of people be n. For 1 person, we need (n-1) strings since he/she ties himself/herself with everyone else except for their own self, therefore "n-1". Since 1 person requires n-1 strings, n people will require n X (n-1) strings. But wait, here is the catch- if you observe carefully, for every pair of people, only 1 string is required but here we have counted it twice. Therefore, to delete the extra strings we divide the obtained expression by 2 : n(n-1)/2 (this gives no. of strings required) Now, its pretty simple after this: Just solve the inequality n(n-1)/2 <1000 , by solving quadratic equation or by trial method and you will get the answer as 45.

Jayesh Narayan
Mar 1, 2014

I Discovered that in a polygon - The sum of no of sides + the sum of no of diagonals = n(n-1)/2
where n is the no of sides of the polygon. Eg in a triangle - 3(3-1)/2 = 6/2 = 3 since a triangle has no diagonals it gives the no of sides - 3 + diagonals - 0 >>> 3+0 = 3 In Hexagon - 6(5)/2 = 15 .. Hexagon has 6 sides and 9 diagonals ... 6+9 = 15.

So I just used the formula which I just discovered.. Wow.. n(n-1)/2 < 2000 and got the value as 45... I Just Discovered a Formula to solve this... and for no of diagonals + sides.

Here the number of strings are less than 1000. And the number of strings we need for n people to do the necessary connections in n C 2 so n C 2<1000 => n(n-1) <2000 So we need to check for the product of two consecutive numbers whose product is very near to 2000 and less than 2000. So the pair is 45, 44.

So n = 45

use excel to calculate the combination nC2, by increasing the value of n and using the formula COMBIN(n,2) , for n=45 we will get 990 strings and for n=46 we get 1035 strings, so 45 is the answer

If there are 'n' persons, then the number of strings needed to connect them is n (n-1)/2 Given, n (n-1)/2<100, solving for "n" gives 45..

sorry, in 2nd line... n(n-1)<1000

Srilatha Padmanabhan - 7 years, 3 months ago
Abrar Fidvi
Feb 17, 2014

lets think the number of people is X . a string is hold by two people only so the format of the combination will be (number of people=X)C2 . If there is is 3 people then the number of string will be 3C2=3 , if there is 4 people then the number of string will be 4C2 = 6 . as there is X number of people so the formula will be like

XC2 = X! / [ 2! ( n - 2 ) ! ] = X(X - 1 ) / 2 = 999 .

Here 999 come from the question , as it is said that number of person will be less than 1000 . from that formula we will get to value of X that are -44.201 ( which is inappropriate ) and other value is 45.201 . so the answer is 45 .

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...