I have the database movies (movie_id INT, actor VARCHAR(80)) and i want to answer to this question
’Six degrees of separation’: Given two actor names, determine their ’degree of separation’, defined as 1 follows: Two actors ’A’ and ’B’ are 1-degree away if they played in at least one movie together; they are 2-degrees away if there exists an actor ’C’ who is 1-degree away from each of ’A’ and ’B’; and so on.
Do you have any idea how i can do this ?
Thank you
xxmp 0 Light Poster
smantscheff 265 Veteran Poster
jkon 638 Posting Whiz in Training Featured Poster
smantscheff 265 Veteran Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.