Loading...

Messages

Proposals

Stuck in your homework and missing deadline? Get urgent help in $10/Page with 24 hours deadline

Get Urgent Writing Help In Your Essays, Assignments, Homeworks, Dissertation, Thesis Or Coursework & Achieve A+ Grades.

Privacy Guaranteed - 100% Plagiarism Free Writing - Free Turnitin Report - Professional And Experienced Writers - 24/7 Online Support

Molecular weight by freezing point depression lab answers

04/10/2021 Client: muhammad11 Deadline: 2 Day

Write a C++ program called ts.cpp that implements the topological sorting algorithm based on the DFS algorithm. Your program should read an input file name and determine if the input graph is a DAG (= directed acyclic graph) or not. If the graph is not a DAG, your program has to stop without further processing. However, if it’s a DAG, your program should display the starting node(s), popping-off order, and topologically sorted list. In the problem, you can assume that the number of nodes in the input file is less than 100.

When we grade your programming assignment, we will use the g++ compiler on the cloud9. So, you must use the cloud9 for the homework. Additionally, you must include five items such as “Title”, “Abstract”, “Class ID”, “Name”, and “Date” at the beginning of the program as head comments.

Input file format: This is a sample input file called t1.txt.

3

2

0 1

1 2

The first line (= 3 in the example) indicates that there are three vertices in the graph. The second line (= 2 in the example) presents the number of edges in the graph. The remaining two lines are the edge information in the graph. For the homework, you should assume that the first vertex starts from the number 0. Thus, t1.txt describes a directed graph like below:

One blank space is used to delimiter the data. Note that there’s no blank space at the end of each line. If your program does not read the file properly, your program will get no credit. And also, note that you used this format at the homework 2.

This is a sample run of the program on the cloud9. Your program should be compiled and executed exactly like this.

$ g++ -o ts ts.cpp

$ ./ts

Enter a filename: C:\\tmp\\t1.txt

This is a DAG.

Start node(s): 0

Popping-off order: 2 1 0

Topological sort: 0 -> 1 -> 2

In the program, your program has to follow our convention (= ascending order) as you learned in the class.

This is another sample input file called t2.txt.

4

4

0 1

1 2

2 3

3 1

t2.txt describes a directed graph like below:

This is a sample run on the cloud9:

$ g++ -o ts ts.cpp

$ ./ts

Enter a filename: C:\\tmp\\t2.txt

This is not a DAG.

This is the last sample input file called t3.txt.

5

5

2 3

3 4

1 2

0 2

2 4

t3.txt describes a directed graph like below:

This is a sample run on the cloud9:

$ g++ -o ts ts.cpp

$ ./ts

Enter a filename: C:\\tmp\\t3.txt

This is a DAG.

Start node(s): 0 1

Popping-off order: 4 3 2 0 1

Topological sort: 1 -> 0 -> 2 -> 3 -> 4

Again, your program must follow our convention (= ascending order). Thus, your program starts from the node 0 between the two possible starting nodes 0 and 1.

Homework is Completed By:

Writer Writer Name Amount Client Comments & Rating
Instant Homework Helper

ONLINE

Instant Homework Helper

$36

She helped me in last minute in a very reasonable price. She is a lifesaver, I got A+ grade in my homework, I will surely hire her again for my next assignments, Thumbs Up!

Order & Get This Solution Within 3 Hours in $25/Page

Custom Original Solution And Get A+ Grades

  • 100% Plagiarism Free
  • Proper APA/MLA/Harvard Referencing
  • Delivery in 3 Hours After Placing Order
  • Free Turnitin Report
  • Unlimited Revisions
  • Privacy Guaranteed

Order & Get This Solution Within 6 Hours in $20/Page

Custom Original Solution And Get A+ Grades

  • 100% Plagiarism Free
  • Proper APA/MLA/Harvard Referencing
  • Delivery in 6 Hours After Placing Order
  • Free Turnitin Report
  • Unlimited Revisions
  • Privacy Guaranteed

Order & Get This Solution Within 12 Hours in $15/Page

Custom Original Solution And Get A+ Grades

  • 100% Plagiarism Free
  • Proper APA/MLA/Harvard Referencing
  • Delivery in 12 Hours After Placing Order
  • Free Turnitin Report
  • Unlimited Revisions
  • Privacy Guaranteed

6 writers have sent their proposals to do this homework:

Coursework Helper
Homework Guru
Academic Mentor
Instant Homework Helper
Accounting & Finance Master
Essay & Assignment Help
Writer Writer Name Offer Chat
Coursework Helper

ONLINE

Coursework Helper

I have read your project details. I can do this within your deadline.

$26 Chat With Writer
Homework Guru

ONLINE

Homework Guru

I have read and understood all your initial requirements, and I am very professional in this task.

$21 Chat With Writer
Academic Mentor

ONLINE

Academic Mentor

I have read and understood all your initial requirements, and I am very professional in this task.

$47 Chat With Writer
Instant Homework Helper

ONLINE

Instant Homework Helper

I will cover all the points which you have mentioned in your project details.

$26 Chat With Writer
Accounting & Finance Master

ONLINE

Accounting & Finance Master

I have read your project details. I can do this within your deadline.

$27 Chat With Writer
Essay & Assignment Help

ONLINE

Essay & Assignment Help

I will cover all the points which you have mentioned in your project details.

$39 Chat With Writer

Let our expert academic writers to help you in achieving a+ grades in your homework, assignment, quiz or exam.

Similar Homework Questions

Spybot rootkit scan no admin in acl - I am special god made me - How to measure horizontal distance using theodolite - Assessment for crisis intervention a triage assessment model - August 10 Week 3 project - Big data analytics case studies ppt - Wgu c229 time log obesity - Discussion - Assignment: Performance Management System Design - Solving rational inequalities worksheet - Formalization in organizational structures tends to - Personal and professional development in nursing - Merck ivermectin case - Question ans - Biotic factors of a rainforest - Cisco intrusion prevention system - Principles of geotechnical engineering 9th edition solutions - Everyday series evangelism earley and wheeler - A&p by john updike questions and answers - Buenos aires in english translation - How do you say amen in latin - The iodine clock reaction lab calculations - Milky colored fluid secreted from the prostate gland - Fisher price double poppin dino troubleshooting - Rock paper scissors lizard spock java program code - Oabc format - It doesn t matter case study - Converting a linear program to canonical form - Dc motor armature winding diagram - Newry chamber of commerce - Spss correlation table apa format - Just checking monitoring system - Case Study - 9 4 proportional parts and triangles - Cv1 coffee maker brew basket - 501c1 - Clipsal 30 2nm wiring diagram - Plop plop fizz fizz lab answers - Electron configuration of lithium - Daily routine of a medieval monk - Culture of international business - The eve of st agnes stanza 23 analysis - Customer involvement is on a b2c specialty purchase - Virginia henderson nursing theory pdf - Kendall electric battle creek - DMS 100 - Quotes on racism in to kill a mockingbird - Information tech - What is the difference between “you-messages” and “i-messages”? give an example of each. - Information technology - Pregnancy - Monash university engineering prerequisites - Consumer buying behavior in france - Directed reading for content mastery section 3 simple machines - What is a compound machine - Ati active learning template basic concept management of care - Ie 4000 8t4g e - Adapting product labels for international markets - The decision to outsource opens the firm up to certain risks, among them _________ and ________. - Suppose the baseball hall of fame in cooperstown - Escience lab kit redemption card - Australian variety theatre archive - Factory act in 1833 - Multi step income statement mcgraw hill - Pcli lasik - Right sided ecg placement - What is a hemisphere - Current Events Article (4 paragraphs total) - St pauls college usyd - Great spirits have always encountered violent opposition meaning - Measure of Sucess - The party line rachel rafelman - Academic Success and Professional Development Plan Template. - Cloud Computing Research paper - Assignment Statistics - Martha rogers theory of unitary human beings pdf - Origo stepping stones 2.0 grade 4 answers - Discussion 4 managerial accounting - The newsroom america is not the greatest country - Voices of an emerging nation unit test part 2 - Leadership styles project management pmbok - A level economics sample answers - Your firm has identified three potential investment projects - Dissertation Research topic for approval - Curtin university notice board - HUM101: World Religion and Cultures - Experiment 1 kidney filtration - Energy and efficiency worksheet - Why cell phones should be in school - Introduction to measurement lab answer key - 10 core rules of netiquette - Cardiff metropolitan university moodle - Collective noun for umbrellas - Creating a company culture for security example - Wheeled coach case study solution - Monash exam timetable release - What does scroll lock do - Peer Review - Week 4 Gerontology Essay - Secure software development concepts support protecting applications