Maurice Tutor

(5)

$15/per page/Negotiable

About Maurice Tutor

Levels Tought:
Elementary,Middle School,High School,College,University,PHD

Expertise:
Algebra,Applied Sciences See all
Algebra,Applied Sciences,Biology,Calculus,Chemistry,Economics,English,Essay writing,Geography,Geology,Health & Medical,Physics,Science Hide all
Teaching Since: May 2017
Last Sign in: 398 Weeks Ago, 5 Days Ago
Questions Answered: 66690
Tutorials Posted: 66688

Education

  • MCS,PHD
    Argosy University/ Phoniex University/
    Nov-2005 - Oct-2011

Experience

  • Professor
    Phoniex University
    Oct-2001 - Nov-2016

Category > Computer Science Posted 17 Sep 2017 My Price 7.00

flow graph G

You are given a flow graph G. The flow graph G has N vertices numbered from 1 to N. 1 is Source and N is Sink.
There is no incoming edge into Source and no outgoing edge from Sink. There is either edge (u,v) or (v,u) in G. You are also given the capacity of each edges. Assume all capacities are positive integers.
You calculated the maximum flow value in G. Now capacity of exactly one edge is increased by some positive integer value but not more than 1000.
And you found that there was no change in maximum flow.
Now your task is to find out that how many such edges are present in the graph G.

Input

First line will contain two integers N and E separated by space, where N is the number of vertices and
E is the number of edges.
Next E lines will contain 3 integers u, v and c separated by space. Which means is that there is an edge from u to v having capacity c.

Output

You have to output an integer which is the number of edges(one at a time) for which increase in their capacity by not more than 1000 will not lead to increase in maximum flow.

Input Constrain:

2

Example:

Input: 4 5 1 2 8 1 3 10 2 3 5 2 4 2 3 4 3 Output: 3

Explanation:

Increasing the capacity of edge (1,2),(1,3) and (2,3) (INDIVIDUALLY) does not have any effect on maximum flow.

Answers

(5)
Status NEW Posted 17 Sep 2017 05:09 AM My Price 7.00

Hel-----------lo -----------Sir-----------/Ma-----------dam-----------Tha-----------nk -----------You----------- fo-----------r u-----------sin-----------g o-----------ur -----------web-----------sit-----------e a-----------nd -----------and----------- ac-----------qui-----------sit-----------ion----------- of----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n.P-----------lea-----------se -----------pin-----------g m-----------e o-----------n c-----------hat----------- I -----------am -----------onl-----------ine----------- or----------- in-----------box----------- me----------- a -----------mes-----------sag-----------e I----------- wi-----------ll

Not Rated(0)