This is a quick tutorial for implementing graph data structure with adjacency list representation. Once I was looking on the web to have a simple introductory tutorial on graphs, but unfortunately couldn’t find one simple enough. So I decided to write this. In the adjacency list representation, è All the vertices are stored in an array of structure containing ‘data’ and ‘link’ fields. è The linked chains represent the edges of a vertex with its neighbors. In the figure, there are 6 vertices, represented by the array of length 6, and the chains represent the edges. Below is another example: Let us first define the structure of a vertex in a graph. struct vertex { int vertexKey; struct edge *edgePtr; }vertex; The vertexKey is the data field of the vertex, and edgePtr is the edge pointer, declared next. The graph can be declared as: struct vertex graph[10]; int vertexCount=0; Here...
Palak Johal, claimed the title of 10th season of famous MTV reality show Roadies, Battle For Glory. Palak, who proved himself the strongest contestant, defeated 15 contestants and took home a cheque of Rs 4,50,000 and a Hero bike. The other Hero Roadies X Contestants of the finale were Raman Deep, Mohit and Anirudh. Palak- Winner of Roadies X The final episode of Roadies X began with all the eliminated Roadies entering the location where they clashed with the final four. These four were the finalites: The two boys got eliminated in the rope task. So the ultimate battle was between Ramandeep and Palak. Too bad, isn't it.. most of us wanted Mohit or Anirudh to claim the title. So, the final battle concluded to between Ramandeep and Palak! And finally, Palak Claimed the title of Roadies X, battle for glory !!! Like always Raghu Ram, his twin brother Rajiv Laxman and Rannvijay were the judges. How did you like the 10th s...
When I (Anil Kishore) started taking part in algorithmic programming contests, for more than two years, it was just me, lot of problems, very few algorithms, my ideas and my Java codes. With that, I would have probably been still a green rated coder, working for a software company in Bangalore after moving between two or three places, still in search of the right things to do. But why ? Problems, Algorithms, my Ideas and my Codes.. what else I need ? This is where many Indian coders make mistake. Almost two years after joining TopCoder (TC), I started interacting with fellow coders, knowing more about them, reading lots of others codes, being active in forums and part of the wonderful community. That was the crucial part of my career so far. TC has some interviews of foreign coders and they are very interesting to read. Knowing more about our own Indian coders will be more fun, especially for beginners to get inspired. This is the least I can contribute to the wonderful community tha...
Comments
Post a Comment