Rank the list elements in terms of distance, Computer Engineering

Assignment Help:

Q. Rank the list elements in terms of distance?

Rank the list elements in terms of distance from each to last element in given linear linked list.

A parallel algorithm for this problem is given below. The algorithm presumes there are p number of processors.

Algorithm:

Processor j, 0≤ j

if next[j]=j then 

rank[j]=0

else rank[j] =1

endif

while rank[next[first]]≠0 Processor j, 0≤ j

rank[j]=rank[j]+rank[next[j]]

next[j]=next[next[j]]

endwhile

The working of above algorithm is explained by the diagram below:

1844_Rank the list elements in terms of distance.png

Figure: Finding rank of elements


Related Discussions:- Rank the list elements in terms of distance

Double negation - artificial intelligence, Double Negation - Artificial int...

Double Negation - Artificial intelligence: Always parents are correcting their children for the use of double negatives, but we have to be very alert with them in natural langu

Advanced topics of html, HTML is made up of many elements, a lot of them ar...

HTML is made up of many elements, a lot of them are overlooked. Though you can develop a Website with the basic knowledge of HTML, to take benefit of many of the advanced features,

Buses - computer architecture, Buses: Execution of 1 instruction ne...

Buses: Execution of 1 instruction need the following 3 steps to be performed by the CPU: I.  Fetch the contents of the memory location pointed at by the computer syst

Classification of digital computer, CLASSIFICATION  OF DIGITAL COMPUTER ...

CLASSIFICATION  OF DIGITAL COMPUTER Computer are classified under a number of factors.Some people classify them according to their processing speed.main memory,technology used

What does a lock object involve, What does a lock object involve? The t...

What does a lock object involve? The tables. The lock argument.

Observations of high level language program, Q. Observations of High Level ...

Q. Observations of High Level Language Program? Observations Integer constants appeared nearly as frequently as structures or arrays. Most of the scalars were foun

Where virtual memory is used, Where Virtual memory is used ? Ans. Virtu...

Where Virtual memory is used ? Ans. Virtual memory is utilized in all main commercial operating systems.

Explain the term- signals, Explain the term- Signals -  Signals are use...

Explain the term- Signals -  Signals are used for communication between components -  Signals can be seen as real, physical signals -  Some delay should be incurred in a

Explain about transmission media, Q. Explain about Transmission Media? ...

Q. Explain about Transmission Media? These, also known as physical channels, can be either bounded or unbounded. Bounded media, in which signals representing data are confined

How address resolution is performed with table lookup, How address resoluti...

How address resolution is performed with table lookup? Explain with the help of a suitable example. The approach of table lookup to address resolution needs a data structure wh

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd