Question

In C programming, If you wanted to create a memory implementation of the subway map of...

In C programming, If you wanted to create a memory implementation of the subway map of NYC what type of data structure seems most useful? Can you describe at a high level how you might achieve this using a multilinked linked list? If you did how would you use this implementation to list transfer points between trains?

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Yes we can implement subway map of NYC using multilinked linked list. Here we can implement every station as a node. And they will be linked in form of connecting trains. If there is a train direct from station A to station B, they must be linked. The first node is list must be a dummy one which will point to all nodes who are not linked by any other nodes i.e indicate stations from where trains start. In this way you will have a bag of stains (nodes) liked by links (trains).

Add a comment
Know the answer?
Add Answer to:
In C programming, If you wanted to create a memory implementation of the subway map of...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Describe how you would approach the implementation of an Electronic Health Record (EHR), create a list...

    Describe how you would approach the implementation of an Electronic Health Record (EHR), create a list of tasks that need to be done (project milestones) to achieve this implementation. Who are the subject matter experts that need to be included in this decision-making process? Develop a high-level implementation plan that includes the project milestones (key tasks) that will need to be accomplished. Discuss how long you project this project will take by preparing a timeline for your tasks. Include a...

  • Using C Programming Assignment: Implementing a Reliable Transport Protocol Overview In this laboratory programming assignment, you...

    Using C Programming Assignment: Implementing a Reliable Transport Protocol Overview In this laboratory programming assignment, you will be writing the sending and receiving transport-level code for implementing a simple reliable data transfer protocol. There are two versions of this lab, the Alternating-Bit-Protocol version and the Go- Back-N version. This lab should be fun since your implementation will differ very little from what would be required in a real-world situation. Since you probably don't have standalone machines (with an OS that...

  • Please use C++ CS3358 Insert and delete a node Programming Project 2: The linked list -...

    Please use C++ CS3358 Insert and delete a node Programming Project 2: The linked list - Reference: chapter 18: Create an array of 15 student records that should not be sorted Create a liked list of 15 student record nodes. Each node is a node of one student record from the above unsorted array. The list of student records should be sorted by student ID. (Insert function without sort function to create a linked list.) (If you insert correctly, the...

  • Please write a c++ header file, class implementation file and main file that does all of...

    Please write a c++ header file, class implementation file and main file that does all of the following and meets the requirements listed below. Also include a Output of your code as to show that your program works and functions properly. EXERCISING A DOUBLY-LINKED LIST CLASS This project consists of two parts, the second of which appears below. For the first part, write a class that implements an unordered list abstract data type using a doubly-linked list with pointers to...

  • C++ program, inventory.cpp implementation Mostly need the int load(istream&) function. Implementation: You are supp...

    C++ program, inventory.cpp implementation Mostly need the int load(istream&) function. Implementation: You are supposed to write three classes, called Item, Node and Inventory respectively Item is a plain data class with item id, name, price and quantity information accompanied by getters and setters Node is a plain linked list node class with Item pointer and next pointer (with getters/setters) Inventory is an inventory database class that provides basic linked list operations, delete load from file / formatted print functionalities. The...

  • C++ programming language: In this program you will create a simplified bag that acts like a...

    C++ programming language: In this program you will create a simplified bag that acts like a stack meaning that the Last item inserted is the First Item that comes out. Your backend implementation must use a linked list. The code should pass the test (there's only 1) and there should be no memory leaks. Note that passing the test does not ensure full credit! The functions are listed in the suggested order of implementation but you may implement them in...

  • In this lab, using C++, you will create an abstract data type, using a doubly-linked circular...

    In this lab, using C++, you will create an abstract data type, using a doubly-linked circular structure to store the values and links. You must create it by your own and not use any existing containers. You will need a QueueNode. You can use a struct for this, as each node will not have any associated functions. It will have members for data, and the next and previous pointers. Data will be positive integers. There will be no NULL pointers....

  • Programing C Just with #include <stdio.h> We will create a singly linked list of 7 nodes....

    Programing C Just with #include <stdio.h> We will create a singly linked list of 7 nodes. Then, the user will tell us whether to print the “odd-placed” nodes or the “even-placed” nodes. For example, if I had a list of 5 nodes like below, and the user specifies for the odd nodes to be printed, my program would print the values in nodes nl and n3. If the user instead indicated for the even nodes to be printed, my program...

  • Complete number 5 please and thank you DISCUSSION QUESTIONS 1. Think of a recent purchase you...

    Complete number 5 please and thank you DISCUSSION QUESTIONS 1. Think of a recent purchase you have made and 4. Describe how derived demand might affect a college campus bookstore. describe the actions you took at each stage of the consumer decision-making process. Did you skip . Pick a company that you or someone in your fam- any of the stages? Which stage do you think should be most important to marketers? Does it depend on what type of product...

  • Need help with this 1. In particular, suppose you wanted to create a new Web page X, and add it t...

    Need help with this 1. In particular, suppose you wanted to create a new Web page X, and add it to the network in the above network, so that it could achieve a (normalized) authority score that is as large as possible. One thing you might try is to create a second page Y as well, so that Y links to X and thus confers authority on it. In doing this, it's natural to wonder whether it helps or hurts...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT