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

Security plan for a medium sized health care facility. - Macbeth act 3 quotes - Hr policies and procedures manual doc - Compare and contrast fairy tales from different cultures - Short amswer - Percentage of copper in brass experiment - Onboarding strategies to supercharge millennial employees - Lady manners sixth form - Flu - Rose bay secondary college library - Organisational behaviour pdf free download - Csec english sba reflection sample - N491 Discussion Mod 6: - John gardner writing exercises - Franklin equipment ltd case study answers - Amnesia the dark descent elevator machine instructions - Reading comprehension for grade 8 with questions and answers pdf - Main issue for my Organisation in addressing a solution to Evidence based practice nursing practice - Final Project Milestone Three: Global HR, Diversity, Risk Management, and Social Responsibility - How many milliliters in a litre - Abdc journal list pdf - Bertrand russell thought philosophy was important because - Hb fuller resistol - Write a five sentence paragraph using chronological order - Outer worlds force schematics orson or gladys - Allianz oshc claim online - Cloud_Computing_week10 - Probate fee list leaflet pa3 - Why is alessi successful - Integrity - Create a blog post... part 1 rough draft. - Anthony red hot chili peppers biography - Causes of perceptual distortion - Sounds incorporated william tell overture - Describe the error in the conclusion - Order 2534029: Math ( 16 math questions ) - Unearthed arcana 5e feats - Gibson dunn london office - Michael kirby net worth - Aero automatic sprinkler company lawsuit - System Design - Spss - 2 - Managerial hubris and ethical decision making - Taxi subsidy scheme wa - The dolls house theme - Malik c++ programming exercises solutions - Adolescent Cognitive Development - Lutheranism beliefs about sin and salvation - List of cb codes - Mountain dew harvard case study - The anticodon of a particular trna molecule is - Alisha incorporated manufactures medical stents - Spirit of math assignment of the year 1846 - Maul, inc., a calendar year s corporation, incurred the following items. - Persuasive essay about using cellphones in school - Psychology Paper - Sir gawain and the green knight answer key - Microscope diagram with labels - Cabela's women's trans alaska elite goose down parka - Discussion post - RACIAL JUSTICE REFORM AND PRO SPORTS. - Why is the 1938 day of mourning significance - Ardex all purpose concrete resurfacer - Sms guest house knust - Pirate bay safe to use - Lección 7 | grammar quiz - 3.2 1.9 packet tracer answers - Gainmax shelf tech system - Lohmeyer corporation reports - DISCUSSIONS AND REFLECTION - Subway surfers player not authenticated - What does it mean to discern your vocation - Tipler physics 6th edition pdf - Red rooster pay rate 16 year old - Inwald personality inventory technical manual - Outline the stages of a health promotion project - Tableau for qualitative data - Il capitano modern examples - The author of acts is clearly not an eyewitness of much of what he writes about. - Weight of brine water per gallon - Fluke 5500a calibrator price - Charging by friction definition - Data is sent through the network in bundles called - What does working credit on centrelink mean - Knowledge Management - Article Summary and how organizational culture is used within your organization - In deep nights i dig for you like treasure - Conquerors poem henry treece analysis - Atp cp system in basketball - C program for dining philosopher problem - Dfas travel voucher form - probability - Penn foster information literacy lesson 1 exam answers - PSC1515 Miami Florida is considered ground zero for climate change, in particular rising seas will not only drown coastal sections of the city but will disrupt our local supply of drinking water. - Need this by tomorrow the 12th. Details are posted. - Master of disguise jaws quote - Garbage record book entries example - How did red bull become successful - Manageengine servicedesk plus 7.6 0 exploit db - Obs meaning in aged care - As 4100 latest version